Fix -Wuninitialized warnings.
This commit is contained in:
parent
be3ccd9c2b
commit
2c67cb8b7a
3 changed files with 15 additions and 8 deletions
|
@ -112,7 +112,7 @@ cisco_kod_request (char *arg, int from_tty)
|
|||
int done = 0, i;
|
||||
int fail = 0;
|
||||
|
||||
char **sync_ids;
|
||||
char **sync_ids = NULL;
|
||||
int sync_len = 0;
|
||||
int sync_next = 0;
|
||||
char *prev_id = NULL;
|
||||
|
@ -216,12 +216,8 @@ cisco_kod_request (char *arg, int from_tty)
|
|||
buffer[off + 8] = '\0';
|
||||
off += 9;
|
||||
|
||||
if (sync_len == 0)
|
||||
sync_ids = (char **) xmalloc (count * sizeof (char *));
|
||||
else
|
||||
sync_ids = (char **) xrealloc (sync_ids,
|
||||
(sync_len + count) * sizeof (char *));
|
||||
sync_len += count;
|
||||
sync_ids = (char **) xrealloc (sync_ids, sync_len * sizeof (char *));
|
||||
|
||||
for (i = 0; i < count; ++i)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue