some more memory leak fixes (11745)

This commit is contained in:
Sven Wischnowsky 2000-06-05 07:57:27 +00:00
parent d1813a007f
commit f94e5d78b0
4 changed files with 10 additions and 4 deletions

View file

@ -1,3 +1,8 @@
2000-06-05 Sven Wischnowsky <wischnow@zsh.org>
* 11745: Src/builtin.c, Src/Modules/parameter.c, Src/Zle/compresult.c:
some more memory leak fixes
2000-06-04 Bart Schaefer <schaefer@zsh.org>
* 11743: Completion/Linux/_rpm: Complete http as well as ftp URLs

View file

@ -192,9 +192,10 @@ scanpmparameters(HashTable ht, ScanFunc func, int flags)
static void
setpmcommand(Param pm, char *value)
{
if (isset(RESTRICTED))
if (isset(RESTRICTED)) {
zwarn("restricted: %s", value, 0);
else {
zsfree(value);
} else {
Cmdnam cn = zcalloc(sizeof(*cn));
cn->flags = HASHED;

View file

@ -1168,7 +1168,7 @@ void
comp_list(char *v)
{
zsfree(complist);
complist = ztrdup(v);
complist = v;
onlyexpl = (v ? ((strstr(v, "expl") ? 1 : 0) |
(strstr(v, "messages") ? 2 : 0)) : 0);

View file

@ -2162,7 +2162,7 @@ mkautofn(Shfunc shf)
p->strs = NULL;
p->shf = shf;
p->npats = 0;
p->pats = NULL;
p->pats = (Patprog *) p->prog;
p->flags = EF_REAL;
p->dump = NULL;