summaryrefslogtreecommitdiff
path: root/editors
diff options
context:
space:
mode:
Diffstat (limited to 'editors')
-rw-r--r--editors/sed.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/editors/sed.c b/editors/sed.c
index 66dfa15..8061964 100644
--- a/editors/sed.c
+++ b/editors/sed.c
@@ -851,7 +851,8 @@ extern int sed_main(int argc, char **argv)
int i;
FILE *file;
for (i = optind; i < argc; i++) {
- if (file = wfopen(argv[i], "r")) {
+ file = wfopen(argv[i], "r");
+ if (file) {
process_file(file);
fclose(file);
} else