[git commit master] getprotoent_r: use correct define for return value

Bernhard Reutner-Fischer rep.dot.nop at gmail.com
Sat Jan 23 23:47:33 UTC 2010


commit: http://git.uclibc.org/uClibc/commit/?id=d2924a76c315a4cd0f4649511c55b08422b06342
branch: http://git.uclibc.org/uClibc/commit/?id=refs/heads/master

Doesn't correctly set result=NULL on error or EOF.

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop at gmail.com>
---
 libc/inet/getproto.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/libc/inet/getproto.c b/libc/inet/getproto.c
index c297a65..bf7c093 100644
--- a/libc/inet/getproto.c
+++ b/libc/inet/getproto.c
@@ -144,7 +144,7 @@ int getprotoent_r(struct protoent *result_buf,
     }
 again:
     if ((p = fgets(line, BUFSIZ, protof)) == NULL) {
-	rv=TRY_AGAIN;
+	rv=ENOENT;
 	goto DONE;
     }
 
-- 
1.6.3.3



More information about the uClibc-cvs mailing list