Module: sip-router
Branch: master
Commit: 7134959725011baa504a027c4561e0054dd907ae
URL:
http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=7134959…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Wed May 14 23:37:54 2014 +0200
kamcmd: proper size for memset, based on malloc
---
utils/sercmd/sercmd.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/utils/sercmd/sercmd.c b/utils/sercmd/sercmd.c
index 00f10e7..fb9c0a3 100644
--- a/utils/sercmd/sercmd.c
+++ b/utils/sercmd/sercmd.c
@@ -1499,7 +1499,7 @@ static int get_mi_list(int s)
/* alloc the mi_cmds array */
mi_cmds=malloc(mi_which_results*sizeof(*mi_cmds));
if (mi_cmds==0) goto error_mem;
- memset(mi_cmds, 0, mi_which_results* sizeof(mi_cmds));
+ memset(mi_cmds, 0, mi_which_results* sizeof(*mi_cmds));
/* get the mi names list */
for (r=0; r<mi_which_no; r++){
if (mi_which_array[r].type!=BINRPC_T_STR)