diff options
author | markw <markw@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2001-05-14 20:44:26 +0000 |
---|---|---|
committer | markw <markw@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2001-05-14 20:44:26 +0000 |
commit | ba97d5cfe9a697d54af21a40f54388dfdc405e76 (patch) | |
tree | 7e00d66b28bb4d32b06601726d91c6a2128fbee8 /sed.c | |
parent | 5f5a752ef858207f975e3b23382b45db93d6e3c4 (diff) | |
download | busybox-w32-ba97d5cfe9a697d54af21a40f54388dfdc405e76.tar.gz busybox-w32-ba97d5cfe9a697d54af21a40f54388dfdc405e76.tar.bz2 busybox-w32-ba97d5cfe9a697d54af21a40f54388dfdc405e76.zip |
...Need to print just a few more newlines.
git-svn-id: svn://busybox.net/trunk/busybox@2641 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'sed.c')
-rw-r--r-- | sed.c | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -579,7 +579,10 @@ static int do_subst_command(const struct sed_cmd *sed_cmd, const char *line) | |||
579 | 579 | ||
580 | /* if there's anything left of the line, print it */ | 580 | /* if there's anything left of the line, print it */ |
581 | if (*hackline) | 581 | if (*hackline) |
582 | fputs(hackline, stdout); | 582 | puts(hackline); |
583 | /* otherwise, we need to print a newline */ | ||
584 | else | ||
585 | printf("\n"); | ||
583 | 586 | ||
584 | /* cleanup */ | 587 | /* cleanup */ |
585 | free(regmatch); | 588 | free(regmatch); |
@@ -594,7 +597,7 @@ static int do_sed_command(const struct sed_cmd *sed_cmd, const char *line) | |||
594 | switch (sed_cmd->cmd) { | 597 | switch (sed_cmd->cmd) { |
595 | 598 | ||
596 | case 'p': | 599 | case 'p': |
597 | fputs(line, stdout); | 600 | puts(line); |
598 | break; | 601 | break; |
599 | 602 | ||
600 | case 'd': | 603 | case 'd': |