From: octo Date: Sun, 14 May 2006 08:01:55 +0000 (+0000) Subject: Make iterator_get_info return the sequence as an unsigned int, rather than an uint16_t. X-Git-Tag: liboping-0.2.0~8 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=755185bbadf65894df2ae01612a9b2079d905ab0;p=liboping.git Make iterator_get_info return the sequence as an unsigned int, rather than an uint16_t. --- diff --git a/src/liboping.c b/src/liboping.c index b926090..de1ff02 100644 --- a/src/liboping.c +++ b/src/liboping.c @@ -35,10 +35,6 @@ # include #endif -#ifndef __USE_BSD -# define __USE_BSD -#endif - #if HAVE_FCNTL_H # include #endif @@ -1142,10 +1138,10 @@ int ping_iterator_get_info (pingobj_iter_t *iter, int info, /* FIXME Return the sequence as an unsigned int */ case PING_INFO_SEQUENCE: ret = ENOMEM; - *buffer_len = sizeof (uint16_t); - if (orig_buffer_len < sizeof (uint16_t)) + *buffer_len = sizeof (unsigned int); + if (orig_buffer_len < sizeof (unsigned int)) break; - *((uint16_t *) buffer) = (uint16_t) iter->sequence; + *((unsigned int *) buffer) = (unsigned int) iter->sequence; ret = 0; break;