projects
/
oweals
/
busybox.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
30ac01c
)
Changed line[strlen(line) - 1] = '\0'; to chomp(line);
author
Mark Whitley
<markw@lineo.com>
Tue, 17 Apr 2001 18:26:11 +0000
(18:26 -0000)
committer
Mark Whitley
<markw@lineo.com>
Tue, 17 Apr 2001 18:26:11 +0000
(18:26 -0000)
coreutils/sort.c
patch
|
blob
|
history
sort.c
patch
|
blob
|
history
diff --git
a/coreutils/sort.c
b/coreutils/sort.c
index b84453d3a4f17b19670490edb676cbc6b5ecbbb6..5ecca8b8f841157b1404a03767fbbbfe5412e930 100644
(file)
--- a/
coreutils/sort.c
+++ b/
coreutils/sort.c
@@
-71,7
+71,7
@@
int sort_main(int argc, char **argv)
while ((line = get_line_from_file(fp)) != NULL) {
lines = xrealloc(lines, sizeof(char *) * (nlines + 1));
-
line[strlen(line) - 1] = '\0'
;
+
chomp(line)
;
lines[nlines++] = line;
}
}
diff --git
a/sort.c
b/sort.c
index b84453d3a4f17b19670490edb676cbc6b5ecbbb6..5ecca8b8f841157b1404a03767fbbbfe5412e930 100644
(file)
--- a/
sort.c
+++ b/
sort.c
@@
-71,7
+71,7
@@
int sort_main(int argc, char **argv)
while ((line = get_line_from_file(fp)) != NULL) {
lines = xrealloc(lines, sizeof(char *) * (nlines + 1));
-
line[strlen(line) - 1] = '\0'
;
+
chomp(line)
;
lines[nlines++] = line;
}
}