diff options
author | Nick Mathewson <nickm@torproject.org> | 2014-08-13 10:36:06 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2014-08-13 10:39:56 -0400 |
commit | 2bfd92d0d170642fb12f53e5da208f318fdd632c (patch) | |
tree | 09da23f22e58e196fef9995e21b59aff3b555487 /src/or/config.c | |
parent | 5da821a8a3cfffc18f5a656852d98e69cff5dd8f (diff) | |
download | tor-2bfd92d0d170642fb12f53e5da208f318fdd632c.tar.gz tor-2bfd92d0d170642fb12f53e5da208f318fdd632c.zip |
Apply coccinelle script to replace malloc(a*b)->calloc(a,b)
Diffstat (limited to 'src/or/config.c')
-rw-r--r-- | src/or/config.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/or/config.c b/src/or/config.c index bff3e40b8c..2535a72d39 100644 --- a/src/or/config.c +++ b/src/or/config.c @@ -4847,7 +4847,7 @@ parse_client_transport_line(const or_options_t *options, if (!validate_only && !is_useless_proxy) { proxy_argc = line_length-2; tor_assert(proxy_argc > 0); - proxy_argv = tor_malloc_zero(sizeof(char*)*(proxy_argc+1)); + proxy_argv = tor_calloc(sizeof(char *), (proxy_argc + 1)); tmp = proxy_argv; for (i=0;i<proxy_argc;i++) { /* store arguments */ *tmp++ = smartlist_get(items, 2); @@ -5127,7 +5127,7 @@ parse_server_transport_line(const or_options_t *options, if (!validate_only) { proxy_argc = line_length-2; tor_assert(proxy_argc > 0); - proxy_argv = tor_malloc_zero(sizeof(char*)*(proxy_argc+1)); + proxy_argv = tor_calloc(sizeof(char *), (proxy_argc + 1)); tmp = proxy_argv; for (i=0;i<proxy_argc;i++) { /* store arguments */ |