mirror of
https://github.com/RGBCube/serenity
synced 2025-05-14 09:24:57 +00:00
Userland: Fix broken newlines in 'sort'
This commit is contained in:
parent
ab07a713bf
commit
9c8efcd17e
1 changed files with 2 additions and 1 deletions
|
@ -53,7 +53,7 @@ int main([[maybe_unused]] int argc, [[maybe_unused]] char** argv)
|
|||
}
|
||||
if (buflen == -1)
|
||||
break;
|
||||
lines.append(buffer);
|
||||
lines.append({ buffer, AK::ShouldChomp::Chomp });
|
||||
}
|
||||
|
||||
quick_sort(lines, [](auto& a, auto& b) {
|
||||
|
@ -62,6 +62,7 @@ int main([[maybe_unused]] int argc, [[maybe_unused]] char** argv)
|
|||
|
||||
for (auto& line : lines) {
|
||||
fputs(line.characters(), stdout);
|
||||
fputc('\n', stdout);
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue