diff options
author | Mikael Magnusson <mikachu@gmail.com> | 2015-01-05 13:55:11 +0100 |
---|---|---|
committer | Mikael Magnusson <mikachu@gmail.com> | 2015-01-06 23:46:18 +0100 |
commit | 221ecf5010b46afc93a2eec3c132fb8656716247 (patch) | |
tree | d0176624267c7ff31bbfc1953076cae0d73afd84 | |
parent | 18b60d85126ff29aa2bced1d213452a103a313e6 (diff) | |
download | zsh-221ecf5010b46afc93a2eec3c132fb8656716247.tar.gz zsh-221ecf5010b46afc93a2eec3c132fb8656716247.tar.xz zsh-221ecf5010b46afc93a2eec3c132fb8656716247.zip |
34115: compcore: Fix size argument to zfree
Found by Coverity (Issue 1255852), has no impact unless using --enable-zsh-mem, and even then it is minimal.
-rw-r--r-- | ChangeLog | 2 | ||||
-rw-r--r-- | Src/Zle/compcore.c | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog index 384a85208..c31520b69 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,7 @@ 2015-01-06 Mikael Magnusson <mikachu@gmail.com> + * 34115: Src/Zle/compcore.c: Fix size argument to zfree + * 34117: Src/Zle/zle_utils.c: size_t is unsigned, use int instead * 34116: Src/Zle/computil.c: Check for NULL before passing diff --git a/Src/Zle/compcore.c b/Src/Zle/compcore.c index b0c6e06f8..f5056058a 100644 --- a/Src/Zle/compcore.c +++ b/Src/Zle/compcore.c @@ -3492,7 +3492,7 @@ freematch(Cmatch m, int nbeg, int nend) if (m->brsl) zfree(m->brsl, nend * sizeof(int)); - zfree(m, sizeof(m)); + zfree(m, sizeof(*m)); } /* This frees the groups of matches. */ |