aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/c-c++-common/asan/pr63638.c
blob: a8bafc5aad77ebccb5dfd5bf53b16b3baca77b62 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/* { dg-do compile } */

extern
#ifdef __cplusplus
"C"
#endif
void *memcpy (void *, const void *, __SIZE_TYPE__);

struct S{
  long d0, d1, d2, d3, d4, d5, d6;
};

struct S s[6];

int f(struct S *p)
{
  memcpy(p, &s[2], sizeof(*p));
  memcpy(p, &s[1], sizeof(*p));
}