Fixed memory leak in tilde expansion
This commit is contained in:
parent
54935831ff
commit
3a69282b3a
|
|
@ -56,6 +56,7 @@ cp_doglob(wordlist *wlist)
|
|||
for (wl = wlist; wl; wl = wl->wl_next)
|
||||
if (*wl->wl_word == cp_til) {
|
||||
s = cp_tildexpand(wl->wl_word);
|
||||
txfree(wl->wl_word); /* sjb - fix memory leak */
|
||||
if (!s)
|
||||
*wl->wl_word = '\0'; /* MW. We Con't touch tmalloc addres */
|
||||
else
|
||||
|
|
|
|||
Loading…
Reference in New Issue