about summary refs log tree commit diff
path: root/nscd/nscd_getgr_r.c
diff options
context:
space:
mode:
Diffstat (limited to 'nscd/nscd_getgr_r.c')
-rw-r--r--nscd/nscd_getgr_r.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/nscd/nscd_getgr_r.c b/nscd/nscd_getgr_r.c
index 49f4b51304..2d09ed92f2 100644
--- a/nscd/nscd_getgr_r.c
+++ b/nscd/nscd_getgr_r.c
@@ -114,8 +114,8 @@ nscd_getgr_r (const char *key, size_t keylen, request_type type,
   vec[1].iov_base = (void *) key;
   vec[1].iov_len = keylen;
 
-  nbytes = (size_t) TEMP_FAILURE_RETRY (__writev (sock, vec, 2));
-  if (nbytes != sizeof (request_header) + keylen)
+  nbytes = TEMP_FAILURE_RETRY (__writev (sock, vec, 2));
+  if (nbytes != (ssize_t) (sizeof (request_header) + keylen))
     {
       __close (sock);
       return -1;
@@ -123,7 +123,7 @@ nscd_getgr_r (const char *key, size_t keylen, request_type type,
 
   nbytes = TEMP_FAILURE_RETRY (__read (sock, &gr_resp,
 				       sizeof (gr_response_header)));
-  if (nbytes != sizeof (gr_response_header))
+  if (nbytes != (ssize_t) sizeof (gr_response_header))
     {
       __close (sock);
       return -1;