about summary refs log tree commit diff
path: root/src/libunixonacid/unixmessage_handle.c
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2017-02-17 22:30:53 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2017-02-17 22:30:53 +0000
commitfdffefb8032922ce7ffe4c00816072a8ff2148fc (patch)
treebc7313151a429c45d8bab8ad8b9dd32f4e51335f /src/libunixonacid/unixmessage_handle.c
parenta896ca2a8c617e5e00ffd5fc9e69331ad754e5b3 (diff)
downloadskalibs-fdffefb8032922ce7ffe4c00816072a8ff2148fc.tar.gz
skalibs-fdffefb8032922ce7ffe4c00816072a8ff2148fc.tar.xz
skalibs-fdffefb8032922ce7ffe4c00816072a8ff2148fc.zip
More types changes
 New disize
 Add size_t to the autotypes list
 Delete redundant and replace-libc files
 dev_t/ino_t pass
 Big size_t pass
 More things missing, still not operational yet
Diffstat (limited to 'src/libunixonacid/unixmessage_handle.c')
-rw-r--r--src/libunixonacid/unixmessage_handle.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libunixonacid/unixmessage_handle.c b/src/libunixonacid/unixmessage_handle.c
index 52e85cb..9d9de5c 100644
--- a/src/libunixonacid/unixmessage_handle.c
+++ b/src/libunixonacid/unixmessage_handle.c
@@ -2,19 +2,19 @@
 
 #include <skalibs/unixmessage.h>
 
-int unixmessage_handle (unixmessage_receiver_t *b, unixmessage_handler_func_t *f, void *p)
+int unixmessage_handle (unixmessage_receiver_t *b, unixmessage_handler_func_t_ref f, void *p)
 {
   unsigned int n = UNIXMESSAGE_MAXREADS ;
-  int count = 0 ;
+  unsigned int count = 0 ;
   while (n--)
   {
     unixmessage_t m ;
-    register int r = unixmessage_receive(b, &m) ;
+    int r = unixmessage_receive(b, &m) ;
     if (r < 0) return -1 ;
     if (!r) break ;
     r = (*f)(&m, p) ;
     if (r <= 0) return r-2 ;
     count++ ;
   }
-  return count ;
+  return (int)count ;
 }