diff options
author | Denis Vlasenko | 2008-07-13 20:39:23 +0000 |
---|---|---|
committer | Denis Vlasenko | 2008-07-13 20:39:23 +0000 |
commit | 3177ba08522fd49292f37deecc59db0f75b046fd (patch) | |
tree | 2a1ce5c29185a8d0cb27534a2120752ee3f1cfdc /shell/ash.c | |
parent | ad6d6ffcdc9a5aadf604d9411cbee96a974b24c9 (diff) | |
download | busybox-3177ba08522fd49292f37deecc59db0f75b046fd.zip busybox-3177ba08522fd49292f37deecc59db0f75b046fd.tar.gz |
ash: small code shrink
Diffstat (limited to 'shell/ash.c')
-rw-r--r-- | shell/ash.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/shell/ash.c b/shell/ash.c index 08bdfc3..7a63fce 100644 --- a/shell/ash.c +++ b/shell/ash.c @@ -1656,12 +1656,12 @@ struct shparam { static void freeparam(volatile struct shparam *param) { - char **ap; - if (param->malloced) { - for (ap = param->p; *ap; ap++) - free(*ap); - free(param->p); + char **ap, **ap1; + ap = ap1 = param->p; + while (*ap) + free(*ap++); + free(ap1); } } |