xargs: fix my brain fart (resulted in memory leak)
This commit is contained in:
parent
c6758a07c6
commit
8905496444
@ -113,10 +113,10 @@ static xlist_t *process_stdin(xlist_t *list_arg,
|
|||||||
xlist_t *cur;
|
xlist_t *cur;
|
||||||
xlist_t *prev;
|
xlist_t *prev;
|
||||||
|
|
||||||
cur = list_arg;
|
prev = cur = list_arg;
|
||||||
while (1) {
|
while (1) {
|
||||||
prev = cur;
|
|
||||||
if (!cur) break;
|
if (!cur) break;
|
||||||
|
prev = cur;
|
||||||
line_l += cur->length;
|
line_l += cur->length;
|
||||||
cur = cur->link;
|
cur = cur->link;
|
||||||
}
|
}
|
||||||
@ -142,7 +142,6 @@ static xlist_t *process_stdin(xlist_t *list_arg,
|
|||||||
goto set;
|
goto set;
|
||||||
}
|
}
|
||||||
} else { /* if(state == NORM) */
|
} else { /* if(state == NORM) */
|
||||||
|
|
||||||
if (ISSPACE(c)) {
|
if (ISSPACE(c)) {
|
||||||
if (s) {
|
if (s) {
|
||||||
unexpected_eof:
|
unexpected_eof:
|
||||||
@ -214,10 +213,10 @@ static xlist_t *process_stdin(xlist_t *list_arg,
|
|||||||
xlist_t *cur;
|
xlist_t *cur;
|
||||||
xlist_t *prev;
|
xlist_t *prev;
|
||||||
|
|
||||||
cur = list_arg;
|
prev = cur = list_arg;
|
||||||
while (1) {
|
while (1) {
|
||||||
prev = cur;
|
|
||||||
if (!cur) break;
|
if (!cur) break;
|
||||||
|
prev = cur;
|
||||||
line_l += cur->length;
|
line_l += cur->length;
|
||||||
cur = cur->link;
|
cur = cur->link;
|
||||||
}
|
}
|
||||||
@ -304,10 +303,10 @@ static xlist_t *process0_stdin(xlist_t *list_arg,
|
|||||||
xlist_t *cur;
|
xlist_t *cur;
|
||||||
xlist_t *prev;
|
xlist_t *prev;
|
||||||
|
|
||||||
cur = list_arg;
|
prev = cur = list_arg;
|
||||||
while (1) {
|
while (1) {
|
||||||
prev = cur;
|
|
||||||
if (!cur) break;
|
if (!cur) break;
|
||||||
|
prev = cur;
|
||||||
line_l += cur->length;
|
line_l += cur->length;
|
||||||
cur = cur->link;
|
cur = cur->link;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user