mjit.c: fix a mismatch of malloc'ed type
Coverity Scan found this issue.
This commit is contained in:
parent
424ad9a493
commit
8bddf1bc9b
4
mjit.c
4
mjit.c
@ -731,8 +731,8 @@ split_flags(const char *flags)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
char **ret = xmalloc(sizeof(char **) * (i + 1));
|
char **ret = xmalloc(sizeof(char *) * (i + 1));
|
||||||
memcpy((void *)ret, buf, sizeof(char **) * i);
|
memcpy(ret, buf, sizeof(char *) * i);
|
||||||
ret[i] = NULL;
|
ret[i] = NULL;
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user