Set object options to the default values, when creating the object. This may have...
authorocto <octo>
Wed, 19 Apr 2006 12:40:06 +0000 (12:40 +0000)
committerocto <octo>
Wed, 19 Apr 2006 12:40:06 +0000 (12:40 +0000)
src/liboping/liboping.c

index 57de9b5..de66cd5 100644 (file)
@@ -771,6 +771,10 @@ pingobj_t *ping_construct (void)
                return (NULL);
        memset (obj, '\0', sizeof (pingobj_t));
 
+       obj->timeout    = PING_DEF_TIMEOUT;
+       obj->ttl        = PING_DEF_TTL;
+       obj->addrfamily = PING_DEF_AF;
+
        return (obj);
 }