From 0f834b91a4768673833ab4917e87d86c237bb1a6 Mon Sep 17 00:00:00 2001 From: marha Date: Fri, 23 Mar 2012 10:05:55 +0100 Subject: libX11 xserver fontconfig mesa pixman xkbcomp xkeyboard-config git update 23 Mar 2012 --- xorg-server/test/string.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'xorg-server/test/string.c') diff --git a/xorg-server/test/string.c b/xorg-server/test/string.c index e3a5adb6d..93867e04a 100644 --- a/xorg-server/test/string.c +++ b/xorg-server/test/string.c @@ -37,20 +37,20 @@ #include #undef strndup #define strndup my_strndup -char * -strndup(const char *str, size_t n); +char *strndup(const char *str, size_t n); #include "../os/strndup.c" -static void strndup_checks(void) +static void +strndup_checks(void) { - const char *sample="0123456789abcdef"; + const char *sample = "0123456789abcdef"; char *allofit; char *firsthalf = strndup(sample, 8); char *secondhalf = strndup(sample + 8, 8); - assert(strcmp(firsthalf, "01234567") == 0); + assert(strcmp(firsthalf, "01234567") == 0); assert(strcmp(secondhalf, "89abcdef") == 0); free(firsthalf); @@ -61,7 +61,8 @@ static void strndup_checks(void) free(allofit); } -int main(int argc, char** argv) +int +main(int argc, char **argv) { strndup_checks(); -- cgit v1.2.3