diff options
| author | Yusuke Endoh <mame@ruby-lang.org> | 2019-12-03 08:02:38 +0900 |
|---|---|---|
| committer | Yusuke Endoh <mame@ruby-lang.org> | 2019-12-03 08:02:38 +0900 |
| commit | 8bddf1bc9bdd1db7ce2e3fec15f2f06ff355b0a7 (patch) | |
| tree | a4c3c4dcd1ff494169cc8d15f7c59d9ba3c1b54c | |
| parent | 424ad9a49360be56244609c02678e8f055d92073 (diff) | |
mjit.c: fix a mismatch of malloc'ed type
Coverity Scan found this issue.
| -rw-r--r-- | mjit.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -731,8 +731,8 @@ split_flags(const char *flags) } } - char **ret = xmalloc(sizeof(char **) * (i + 1)); - memcpy((void *)ret, buf, sizeof(char **) * i); + char **ret = xmalloc(sizeof(char *) * (i + 1)); + memcpy(ret, buf, sizeof(char *) * i); ret[i] = NULL; return ret; } |
