# HG changeset patch # User diego # Date 1284306457 0 # Node ID bb29c8d135ede80c81bdd7dce4f36ac4bca652da # Parent 7af5fdfdc3d95c2e28754b269b13f1433ea5819b Merge one malloc() + memset() invocation into calloc(). diff -r 7af5fdfdc3d9 -r bb29c8d135ed stream/tvi_def.h --- a/stream/tvi_def.h Sun Sep 12 15:38:21 2010 +0000 +++ b/stream/tvi_def.h Sun Sep 12 15:47:37 2010 +0000 @@ -51,13 +51,13 @@ if (!h) return NULL; - h->priv = malloc(sizeof(priv_t)); + h->priv = calloc(1, sizeof(priv_t)); if (!h->priv) { free(h); return NULL; } - memset(h->priv, 0, sizeof(priv_t)); + h->functions = &functions; h->seq = 0; h->chanlist = -1;