diff options
-rw-r--r-- | editors/sed.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/editors/sed.c b/editors/sed.c index 968d0d2a2..750f41acd 100644 --- a/editors/sed.c +++ b/editors/sed.c | |||
@@ -1191,7 +1191,7 @@ extern int sed_main(int argc, char **argv) | |||
1191 | nonstdout=bb_wfopen(outname,"w"); | 1191 | nonstdout=bb_wfopen(outname,"w"); |
1192 | /* Set permissions of output file */ | 1192 | /* Set permissions of output file */ |
1193 | fstat(fileno(file),&statbuf); | 1193 | fstat(fileno(file),&statbuf); |
1194 | fchmod(fileno(file),statbuf.st_mode); | 1194 | fchmod(fileno(nonstdout),statbuf.st_mode); |
1195 | atexit(cleanup_outname); | 1195 | atexit(cleanup_outname); |
1196 | } | 1196 | } |
1197 | process_file(file); | 1197 | process_file(file); |