# HG changeset patch # User vae # Date 1371328117 0 # Node ID a27026771dae35495a61803375355a903774881c # Parent 283b2c38b41387d28f7c112a95ee691d5961c680 Fix compiler warnings for discrediting const pointer. [ Bugzilla 1001865 ] diff --git a/packages/language/c/libc/string/current/ChangeLog b/packages/language/c/libc/string/current/ChangeLog --- a/packages/language/c/libc/string/current/ChangeLog +++ b/packages/language/c/libc/string/current/ChangeLog @@ -1,3 +1,8 @@ +2013-06-13 Ilija Kocho + + * tests/memchr.c: Fix compiler warnings for discrediting const pointer. + [ Bugzilla 1001865 ] + 2010-05-10 Ross Younger * include/string.h: Declare strnlen. diff --git a/packages/language/c/libc/string/current/tests/memchr.c b/packages/language/c/libc/string/current/tests/memchr.c --- a/packages/language/c/libc/string/current/tests/memchr.c +++ b/packages/language/c/libc/string/current/tests/memchr.c @@ -75,7 +75,8 @@ void cyg_user_start(void) #endif { char x[] = "Your feeble skills are no match for the power of " - "the dark side!"; + "the dark side!"; + char x0[] = ""; void *ret; CYG_TEST_INIT(); @@ -104,7 +105,7 @@ void cyg_user_start(void) CYG_TEST_PASS_FAIL( ret == NULL, "Boundary test 2" ); // Check 6 (boundary condition) - ret = memchr( (void *)"", (int)'\0', 0 ); + ret = memchr(x0, (int)'\0', 0 ); CYG_TEST_PASS_FAIL( ret == NULL, "Boundary test 3" ); // CYG_TEST_NA("Testing is not applicable to this configuration");