diff options
author | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2008-07-23 11:23:36 +0000 |
---|---|---|
committer | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2008-07-23 11:23:36 +0000 |
commit | 1f020b178664857b0e107778d04fb971a58e6230 (patch) | |
tree | c1cd86593b5d354091e0fa3201c5789bec5c53ad /test | |
parent | f1775381f91f1250b20f1949dfd0364ddb0ee9fc (diff) |
- trim any trailing whitespace
Diffstat (limited to 'test')
-rw-r--r-- | test/crypt/md5c-test.c | 2 | ||||
-rw-r--r-- | test/inet/tst-ethers-line.c | 8 | ||||
-rw-r--r-- | test/inet/tst-ethers.c | 2 | ||||
-rw-r--r-- | test/malloc/malloc.c | 2 | ||||
-rw-r--r-- | test/malloc/testmalloc.c | 16 | ||||
-rw-r--r-- | test/malloc/time_malloc.c | 2 | ||||
-rw-r--r-- | test/math/libm-test.inc | 12 | ||||
-rw-r--r-- | test/math/rint.c | 2 | ||||
-rw-r--r-- | test/misc/bug-glob2.c | 4 | ||||
-rw-r--r-- | test/pthread/ex7.c | 6 | ||||
-rw-r--r-- | test/regex/testregex.c | 2 | ||||
-rw-r--r-- | test/setjmp/bug269-setjmp.c | 2 | ||||
-rw-r--r-- | test/stdlib/teststrtol.c | 2 | ||||
-rw-r--r-- | test/string/tester.c | 2 | ||||
-rw-r--r-- | test/time/time.c | 2 |
15 files changed, 33 insertions, 33 deletions
diff --git a/test/crypt/md5c-test.c b/test/crypt/md5c-test.c index e2896b5b1..3c6154021 100644 --- a/test/crypt/md5c-test.c +++ b/test/crypt/md5c-test.c @@ -10,7 +10,7 @@ main (int argc, char *argv[]) char *cp; cp = crypt ("Hello world!", salt); - if (strcmp ("$1$saltstri$YMyguxXMBpd2TEZ.vS/3q1", cp)) { + if (strcmp ("$1$saltstri$YMyguxXMBpd2TEZ.vS/3q1", cp)) { fprintf(stderr, "Failed md5 crypt test!\n"); return EXIT_FAILURE; } diff --git a/test/inet/tst-ethers-line.c b/test/inet/tst-ethers-line.c index 3b3387455..19cf2fbf4 100644 --- a/test/inet/tst-ethers-line.c +++ b/test/inet/tst-ethers-line.c @@ -24,7 +24,7 @@ int main(void) int fd, i; const char *ethers; struct stat statb; - + if ((fd = open(ETHER_FILE_NAME, O_RDONLY)) == -1) { perror ("Cannot open file"); exit(1); @@ -35,14 +35,14 @@ int main(void) exit(1); } ethers = mmap(NULL, statb.st_size, PROT_READ, MAP_SHARED, fd, 0); - + if (ethers == MAP_FAILED) { perror("File mapping failed"); exit(1); - } + } ether_line(ethers, &addr, hostname); - + for (i = 0; i < 6; i++) { printf("%02x", addr.ether_addr_octet[i]); if (i < 5) diff --git a/test/inet/tst-ethers.c b/test/inet/tst-ethers.c index 14b5a4378..6b6e10cd2 100644 --- a/test/inet/tst-ethers.c +++ b/test/inet/tst-ethers.c @@ -14,7 +14,7 @@ int main(void) char host[ETHER_LINE_LEN]; int i; int res = ether_hostton("teeth", &addr); - + if (res) return 1; diff --git a/test/malloc/malloc.c b/test/malloc/malloc.c index d63856845..ca7c5f927 100644 --- a/test/malloc/malloc.c +++ b/test/malloc/malloc.c @@ -67,7 +67,7 @@ int test2(void) } else { free(ptr); } - + ptr = malloc(100); ptr = realloc(ptr, 0); if (ptr) { diff --git a/test/malloc/testmalloc.c b/test/malloc/testmalloc.c index caf08a9e1..42707d231 100644 --- a/test/malloc/testmalloc.c +++ b/test/malloc/testmalloc.c @@ -27,7 +27,7 @@ int main(void) free(y); printf("about to free(0)\n"); free(0); - + x=malloc(13); printf("x = %p\n", x); memcpy(x, "Small string", 13); @@ -37,8 +37,8 @@ int main(void) memcpy(y, "********** Larger string **********", 36); printf("0x%p test string2: %s\n", y, (char *)y); free(y); - - + + printf("Allocate 100 nodes 500 bytes each\n"); save = 0; for (i=0; i<100; i++) { @@ -50,14 +50,14 @@ int main(void) lp->next = save; save = lp; } - + printf("freeing 100 nodes\n"); while (save) { lp = save; save = save->next; free(lp); } - + printf("try realloc 100 times \n"); lp = 0; for (i=1; i<=100; i++) { @@ -71,7 +71,7 @@ int main(void) void *unused_ret = realloc(lp, 0); (void) unused_ret; } - + printf("Allocate another 100 nodes 600 bytes each\n"); save = 0; for (i=0; i<100; i++) { @@ -83,14 +83,14 @@ int main(void) lp->next = save; save = lp; } - + printf("freeing 100 nodes\n"); while (save) { lp = save; save = save->next; free(lp); } - + printf("alloc test PASSED\n"); exit(0); diff --git a/test/malloc/time_malloc.c b/test/malloc/time_malloc.c index 64195107d..0b626654f 100644 --- a/test/malloc/time_malloc.c +++ b/test/malloc/time_malloc.c @@ -1,6 +1,6 @@ #include <stdlib.h> #define REPS (100000) -int sizes[] = { +int sizes[] = { 100000, 1024, 42000, 350, 100, 80, 3 ,3,3,3,3,3,3,3,3,3,3,3,3,50, 100000, 1024, 42000, 350, 100, 80, 3 ,3,3,3,3,3,3,3,3,3,3,3,3,50, 100000, 1024, 42000, 350, 100, 80, 3 ,3,3,3,3,3,3,3,3,3,3,3,3,50, diff --git a/test/math/libm-test.inc b/test/math/libm-test.inc index be6312930..c9c2c8b41 100644 --- a/test/math/libm-test.inc +++ b/test/math/libm-test.inc @@ -4182,14 +4182,14 @@ round_test (void) /* The result can only be represented in long double. */ TEST_f_f (round, 4503599627370495.5L, 4503599627370496.0L); TEST_f_f (round, 4503599627370496.25L, 4503599627370496.0L); - TEST_f_f (round, 4503599627370496.5L, 4503599627370497.0L); + TEST_f_f (round, 4503599627370496.5L, 4503599627370497.0L); TEST_f_f (round, 4503599627370496.75L, 4503599627370497.0L); - TEST_f_f (round, 4503599627370497.5L, 4503599627370498.0L); + TEST_f_f (round, 4503599627370497.5L, 4503599627370498.0L); - TEST_f_f (round, -4503599627370495.5L, -4503599627370496.0L); - TEST_f_f (round, -4503599627370496.25L, -4503599627370496.0L); + TEST_f_f (round, -4503599627370495.5L, -4503599627370496.0L); + TEST_f_f (round, -4503599627370496.25L, -4503599627370496.0L); TEST_f_f (round, -4503599627370496.5L, -4503599627370497.0L); - TEST_f_f (round, -4503599627370496.75L, -4503599627370497.0L); + TEST_f_f (round, -4503599627370496.75L, -4503599627370497.0L); TEST_f_f (round, -4503599627370497.5L, -4503599627370498.0L); TEST_f_f (round, 9007199254740991.5L, 9007199254740992.0L); @@ -4640,7 +4640,7 @@ trunc_test (void) TEST_f_f (trunc, 10141204801825835211973625643008.25L, 10141204801825835211973625643008.0L); TEST_f_f (trunc, 10141204801825835211973625643008.5L, 10141204801825835211973625643008.0L); TEST_f_f (trunc, 10141204801825835211973625643008.75L, 10141204801825835211973625643008.0L); - TEST_f_f (trunc, 10141204801825835211973625643009.5L, 10141204801825835211973625643009.0L); + TEST_f_f (trunc, 10141204801825835211973625643009.5L, 10141204801825835211973625643009.0L); #endif END (trunc); diff --git a/test/math/rint.c b/test/math/rint.c index 399fb90e3..04c195385 100644 --- a/test/math/rint.c +++ b/test/math/rint.c @@ -6,6 +6,6 @@ int main(void) { double d1, d2; d1 = 0.6; d2 = rint(d1); printf("d1 = %f, d2 = %f\n", d1, d2); - return 0; + return 0; } diff --git a/test/misc/bug-glob2.c b/test/misc/bug-glob2.c index 9e8be983b..f8b030e2c 100644 --- a/test/misc/bug-glob2.c +++ b/test/misc/bug-glob2.c @@ -275,7 +275,7 @@ do_test (void) != GLOB_ABORTED) { puts ("glob did not fail with GLOB_ABORTED"); - exit (EXIT_FAILURE); + exit (EXIT_FAILURE); } globfree (&gl); @@ -287,7 +287,7 @@ do_test (void) if (glob ("dir2/*", GLOB_DOOFFS, NULL, &gl) != GLOB_NOMATCH) { puts ("glob did not fail with GLOB_NOMATCH"); - exit (EXIT_FAILURE); + exit (EXIT_FAILURE); } globfree (&gl); diff --git a/test/pthread/ex7.c b/test/pthread/ex7.c index 9cf30aa19..49af18d96 100644 --- a/test/pthread/ex7.c +++ b/test/pthread/ex7.c @@ -48,13 +48,13 @@ test_thread (void *ms_param) status = pthread_cond_timedwait(&foo.cond, &foo.mutex, &timeout); } pthread_mutex_unlock(&foo.mutex); - + /* post the main event */ pthread_mutex_lock(&main_event.mutex); main_event.flag = 1; pthread_cond_signal(&main_event.cond); pthread_mutex_unlock(&main_event.mutex); - + /* that's it, bye */ return (void*) status; } @@ -95,7 +95,7 @@ main (void) printf ("count = %lu\n", count); } - + usleep (10); } diff --git a/test/regex/testregex.c b/test/regex/testregex.c index 3be8680db..3992c2647 100644 --- a/test/regex/testregex.c +++ b/test/regex/testregex.c @@ -1950,7 +1950,7 @@ main(int argc, char** argv) else #endif fun = "regexec"; - + for (i = 0; i < elementsof(match); i++) match[i] = state.NOMATCH; diff --git a/test/setjmp/bug269-setjmp.c b/test/setjmp/bug269-setjmp.c index 33431fa19..b11ac7b24 100644 --- a/test/setjmp/bug269-setjmp.c +++ b/test/setjmp/bug269-setjmp.c @@ -30,7 +30,7 @@ int n_x = 6; static int g_counter = 0; static int -f (void) +f (void) { static int counter = 0; static int way_point1 = 3; diff --git a/test/stdlib/teststrtol.c b/test/stdlib/teststrtol.c index e959b4990..5b43a9b0c 100644 --- a/test/stdlib/teststrtol.c +++ b/test/stdlib/teststrtol.c @@ -10,7 +10,7 @@ const char *strings[]={ "10000000", "100000000", "1000000000", /* negative */ - "-0", "-1", "-10", + "-0", "-1", "-10", "-100", "-1000", "-10000", "-100000", "-1000000", "-10000000", "-100000000", "-1000000000", diff --git a/test/string/tester.c b/test/string/tester.c index 647b8c174..ac1b90118 100644 --- a/test/string/tester.c +++ b/test/string/tester.c @@ -1089,7 +1089,7 @@ test_memcmp (void) { int i, cnt = 1; char one[21], two[21]; - + it = "memcmp"; check(memcmp("a", "a", 1) == 0, cnt++); /* Identity. */ check(memcmp("abc", "abc", 3) == 0, cnt++); /* Multicharacter. */ diff --git a/test/time/time.c b/test/time/time.c index c97c4f5ef..a4d68d50f 100644 --- a/test/time/time.c +++ b/test/time/time.c @@ -4,7 +4,7 @@ /* We use this instead of memcmp because some broken C libraries * add additional nonstandard fields to struct tm... */ - + int tm_cmp(struct tm tm1, struct tm tm2) { return tm1.tm_sec != tm2.tm_sec || |