Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
PATCH 15/17: Don't leak ifs stuff
- X-seq: zsh-workers 34108
- From: Mikael Magnusson <mikachu@xxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: PATCH 15/17: Don't leak ifs stuff
- Date: Tue, 6 Jan 2015 06:25:47 +0100
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:subject:date:message-id:in-reply-to:references; bh=pFOgMrv7CNpX+1aORG8YyO2rw/1sMr7aQ4Hf/hlp64A=; b=Ud9YLIJdS8jR0h0itvLr5VlnN3zxNh7apdRmNL3WktXYeCxcWEhQyzN/9E23bxI8Ur Z1N68RpTKJhBcC2VCvTjvmlVGO4y6XtehlRC3eVFmUWfufcL8AH7g5fovCbEVlujJilC tlEEiXXoSXJYMfLRxVsMIWuu4ZkY70OcdR78v5Eyf18STn2I5qcHg2WR7udlLpk2Ni+n fbeOwBeSfhhs3wKICe19IaIIYHL4Fx9w2PJTmsLM8sooMfXTCLsKVFFuWi3pv57rzPRT dUo2SXd9cnMjTwJcwrXAesnBRmjX33fEEqmnZU7ArZD6eYTcO0aTRU0oXKhp5khhsb1N 5bEw==
- In-reply-to: <1420521949-30483-1-git-send-email-mikachu@gmail.com>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <1420521949-30483-1-git-send-email-mikachu@gmail.com>
Found by Coverity (Issue 1255785).
---
Src/utils.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Src/utils.c b/Src/utils.c
index 390f513..72a0c9c 100644
--- a/Src/utils.c
+++ b/Src/utils.c
@@ -3543,7 +3543,7 @@ inittyptab(void)
for (t0 = (int)STOUC(Snull); t0 <= (int)STOUC(Nularg); t0++)
typtab[t0] |= ITOK | IMETA | INULL;
for (s = ifs ? ifs : EMULATION(EMULATE_KSH|EMULATE_SH) ?
- ztrdup(DEFAULT_IFS_SH) : ztrdup(DEFAULT_IFS); *s; s++) {
+ DEFAULT_IFS_SH : DEFAULT_IFS; *s; s++) {
int c = STOUC(*s == Meta ? *++s ^ 32 : *s);
#ifdef MULTIBYTE_SUPPORT
if (!isascii(c)) {
@@ -3578,7 +3578,7 @@ inittyptab(void)
#ifdef MULTIBYTE_SUPPORT
set_widearray(wordchars, &wordchars_wide);
set_widearray(ifs ? ifs : EMULATION(EMULATE_KSH|EMULATE_SH) ?
- ztrdup(DEFAULT_IFS_SH) : ztrdup(DEFAULT_IFS), &ifs_wide);
+ DEFAULT_IFS_SH : DEFAULT_IFS, &ifs_wide);
#endif
for (s = SPECCHARS; *s; s++)
typtab[STOUC(*s)] |= ISPECIAL;
--
2.2.0.GIT
Messages sorted by:
Reverse Date,
Date,
Thread,
Author