svn commit: trunk/busybox/findutils
vda at busybox.net
vda at busybox.net
Tue Apr 10 14:41:17 PDT 2007
Author: vda
Date: 2007-04-10 14:41:16 -0700 (Tue, 10 Apr 2007)
New Revision: 18393
Log:
xargs: fix my brain fart (resulted in memory leak)
Modified:
trunk/busybox/findutils/xargs.c
Changeset:
Modified: trunk/busybox/findutils/xargs.c
===================================================================
--- trunk/busybox/findutils/xargs.c 2007-04-10 21:40:19 UTC (rev 18392)
+++ trunk/busybox/findutils/xargs.c 2007-04-10 21:41:16 UTC (rev 18393)
@@ -113,10 +113,10 @@
xlist_t *cur;
xlist_t *prev;
- cur = list_arg;
+ prev = cur = list_arg;
while (1) {
- prev = cur;
if (!cur) break;
+ prev = cur;
line_l += cur->length;
cur = cur->link;
}
@@ -142,7 +142,6 @@
goto set;
}
} else { /* if(state == NORM) */
-
if (ISSPACE(c)) {
if (s) {
unexpected_eof:
@@ -214,10 +213,10 @@
xlist_t *cur;
xlist_t *prev;
- cur = list_arg;
+ prev = cur = list_arg;
while (1) {
- prev = cur;
if (!cur) break;
+ prev = cur;
line_l += cur->length;
cur = cur->link;
}
@@ -304,10 +303,10 @@
xlist_t *cur;
xlist_t *prev;
- cur = list_arg;
+ prev = cur = list_arg;
while (1) {
- prev = cur;
if (!cur) break;
+ prev = cur;
line_l += cur->length;
cur = cur->link;
}
More information about the busybox-cvs
mailing list