aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/memchr-3.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gcc.dg/memchr-3.c')
-rw-r--r--gcc/testsuite/gcc.dg/memchr-3.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/testsuite/gcc.dg/memchr-3.c b/gcc/testsuite/gcc.dg/memchr-3.c
index 9a35735..9caa2ac 100644
--- a/gcc/testsuite/gcc.dg/memchr-3.c
+++ b/gcc/testsuite/gcc.dg/memchr-3.c
@@ -17,9 +17,10 @@ struct SX
const struct SX sx = { 0x1221 };
const char sx_rep[] = { };
-void test_find (void)
+int test_find (void)
{
int n = 0, nb = (const char*)&sx.a - (const char*)&sx;
const char *p = (const char*)&sx, *q = sx_rep;
n += p + 1 == memchr (p, q[1], nb);
+ return n;
}