repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Revise -mdisable-fpregs option and add new -msoft-mult option
[official-gcc.git]
/
gcc
/
testsuite
/
gcc.dg
/
strncpy-fix-1.c
blob
b4fd4aa4877a007a546abe65b68e9121966516c0
1
/* Test that use of strncpy does not result in a "value computed is
2
not used" warning. */
3
/* { dg-do compile } */
4
/* { dg-options "-O2 -Wall -Wno-stringop-truncation" } */
5
6
#include <string.h>
7
void
8
f
(
char
*
s
)
9
{
10
strncpy
(
s
,
"::"
,
2
);
11
}