From: Ulrich Drepper Date: Tue, 17 Jul 2001 01:37:42 +0000 (+0000) Subject: Update. X-Git-Tag: cvs/glibc-2_2_4~220 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=98e75a1c9c50e99e46c94623d9a9a8088c4efe30;p=platform%2Fupstream%2Fglibc.git Update. 2001-07-16 Ulrich Drepper * nscd/connections.c: Print messages caused by user application only if debug_level > 0. * nscd/grpcache.c: Likewise. * nscd/hstcache.c: Likewise. * nscd/pwdcache.c: Likewise. --- diff --git a/ChangeLog b/ChangeLog index 66fdd8d..1eb5574 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2001-07-16 Ulrich Drepper + + * nscd/connections.c: Print messages caused by user application + only if debug_level > 0. + * nscd/grpcache.c: Likewise. + * nscd/hstcache.c: Likewise. + * nscd/pwdcache.c: Likewise. + 2001-07-13 H.J. Lu * sysdeps/mips/dl-machine.h (MAP_BASE_ADDR): Removed. diff --git a/nscd/connections.c b/nscd/connections.c index b1cfdbb..47660d7 100644 --- a/nscd/connections.c +++ b/nscd/connections.c @@ -222,9 +222,10 @@ handle_request (int fd, request_header *req, void *key, uid_t uid) if (req->version != NSCD_VERSION) { - dbg_log (_("\ + if (debug_level > 0) + dbg_log (_("\ cannot handle old request version %d; current version is %d"), - req->version, NSCD_VERSION); + req->version, NSCD_VERSION); return; } @@ -254,7 +255,8 @@ cannot handle old request version %d; current version is %d"), /* No, sent the prepared record. */ if (TEMP_FAILURE_RETRY (write (fd, db->disabled_iov->iov_base, db->disabled_iov->iov_len)) - != db->disabled_iov->iov_len) + != db->disabled_iov->iov_len + && debug_level > 0) { /* We have problems sending the result. */ char buf[256]; @@ -275,7 +277,8 @@ cannot handle old request version %d; current version is %d"), { /* Hurray it's in the cache. */ if (TEMP_FAILURE_RETRY (write (fd, cached->packet, cached->total)) - != cached->total) + != cached->total + && debug_level > 0) { /* We have problems sending the result. */ char buf[256]; @@ -433,8 +436,9 @@ nscd_run (void *p) if (TEMP_FAILURE_RETRY (read (fd, &req, sizeof (req))) != sizeof (req)) { - dbg_log (_("short read while reading request: %s"), - strerror_r (errno, buf, sizeof (buf))); + if (debug_level > 0) + dbg_log (_("short read while reading request: %s"), + strerror_r (errno, buf, sizeof (buf))); close (fd); continue; } @@ -467,7 +471,8 @@ nscd_run (void *p) to 1kb. */ if (req.key_len < 0 || req.key_len > 1024) { - dbg_log (_("key length in request too long: %d"), req.key_len); + if (debug_level > 0) + dbg_log (_("key length in request too long: %d"), req.key_len); close (fd); continue; } @@ -479,8 +484,9 @@ nscd_run (void *p) if (TEMP_FAILURE_RETRY (read (fd, keybuf, req.key_len)) != req.key_len) { - dbg_log (_("short read while reading request key: %s"), - strerror_r (errno, buf, sizeof (buf))); + if (debug_level > 0) + dbg_log (_("short read while reading request key: %s"), + strerror_r (errno, buf, sizeof (buf))); close (fd); continue; } diff --git a/nscd/grpcache.c b/nscd/grpcache.c index c23d86e..5e037b5 100644 --- a/nscd/grpcache.c +++ b/nscd/grpcache.c @@ -1,5 +1,5 @@ /* Cache handling for group lookup. - Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc. + Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper , 1998. @@ -187,7 +187,7 @@ cache_addgr (struct database *db, int fd, request_header *req, void *key, pthread_rwlock_unlock (&db->lock); } - if (written != total) + if (written != total && debug_level > 0) { char buf[256]; dbg_log (_("short write in %s: %s"), __FUNCTION__, diff --git a/nscd/hstcache.c b/nscd/hstcache.c index 7cdf18f..3e8c370 100644 --- a/nscd/hstcache.c +++ b/nscd/hstcache.c @@ -1,5 +1,5 @@ /* Cache handling for host lookup. - Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc. + Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper , 1998. @@ -272,7 +272,7 @@ cache_addhst (struct database *db, int fd, request_header *req, void *key, pthread_rwlock_unlock (&db->lock); } - if (written != total) + if (written != total && debug_level > 0) { char buf[256]; dbg_log (_("short write in %s: %s"), __FUNCTION__, diff --git a/nscd/pwdcache.c b/nscd/pwdcache.c index b69a8ca..88990ad 100644 --- a/nscd/pwdcache.c +++ b/nscd/pwdcache.c @@ -1,5 +1,5 @@ /* Cache handling for passwd lookup. - Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc. + Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper , 1998. @@ -183,7 +183,7 @@ cache_addpw (struct database *db, int fd, request_header *req, void *key, pthread_rwlock_unlock (&db->lock); } - if (written != total) + if (written != total && debug_level > 0) { char buf[256]; dbg_log (_("short write in %s: %s"), __FUNCTION__,