This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch] make sure inet/tst-network updates errors properly


the inet/tst-network.c prints out failures, but doesnt actually update the 
errors variable upon failure, so the test always exits with 0 status.
-mike

Attachment: signature.asc
Description: This is a digitally signed message part.

2007-09-14  Mike Frysinger  <vapier@gentoo.org>

	* inet/tst-network.c: Increment errors when res != tests[i].number.

Index: inet/tst-network.c
===================================================================
RCS file: /cvs/glibc/libc/inet/tst-network.c,v
retrieving revision 1.3
diff -u -p -r1.3 tst-network.c
--- inet/tst-network.c	24 Sep 2002 04:21:03 -0000	1.3
+++ inet/tst-network.c	15 Sep 2007 03:58:49 -0000
@@ -61,6 +61,7 @@ main (void)
 
       if (res != tests[i].number)
 	{
+	  ++errors;
 	  printf ("Test failed for inet_network (\"%s\"):\n",
 		  tests[i].network);
 	  printf ("Expected return value %u (0x%x) but got %u (0x%x).\n",

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]