Initialize tid response structure
authorSam Hartman <hartmans@debian.org>
Fri, 5 Apr 2013 16:43:10 +0000 (12:43 -0400)
committerSam Hartman <hartmans@debian.org>
Fri, 5 Apr 2013 16:54:40 +0000 (12:54 -0400)
tid/tids.c

index 13a1355..202c62a 100644 (file)
@@ -209,7 +209,7 @@ static void tids_handle_connection (TIDS_INSTANCE *tids, int conn)
     }
 
     /* Allocate a response structure and populate common fields */
-    if ((NULL == (resp = malloc(sizeof(TID_RESP))))) {
+    if ((NULL == (resp = calloc(sizeof(TID_RESP), 1)))) {
       fprintf(stderr, "Error allocating response structure.\n");
       return;
     }