+2001-07-16 Ulrich Drepper <drepper@redhat.com>
+
+ * 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 <hjl@gnu.org>
* sysdeps/mips/dl-machine.h (MAP_BASE_ADDR): Removed.
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;
}
/* 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];
{
/* 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];
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;
}
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;
}
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;
}
/* 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 <drepper@cygnus.com>, 1998.
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__,
/* 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 <drepper@cygnus.com>, 1998.
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__,
/* 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 <drepper@cygnus.com>, 1998.
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__,