diff options
-rw-r--r-- | editors/sed.c | 7 | ||||
-rw-r--r-- | sed.c | 7 |
2 files changed, 2 insertions, 12 deletions
diff --git a/editors/sed.c b/editors/sed.c index 1c227704e..16e8e1866 100644 --- a/editors/sed.c +++ b/editors/sed.c @@ -577,12 +577,7 @@ static int do_subst_command(const struct sed_cmd *sed_cmd, const char *line) break; } - /* if there's anything left of the line, print it */ - if (*hackline) - puts(hackline); - /* otherwise, we need to print a newline */ - else - printf("\n"); + puts(hackline); /* cleanup */ free(regmatch); @@ -577,12 +577,7 @@ static int do_subst_command(const struct sed_cmd *sed_cmd, const char *line) break; } - /* if there's anything left of the line, print it */ - if (*hackline) - puts(hackline); - /* otherwise, we need to print a newline */ - else - printf("\n"); + puts(hackline); /* cleanup */ free(regmatch); |