mirror of the now-defunct rocklinux.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
706 B

  1. --- sed-4.1/sed/execute.c 2004-03-13 10:30:39.000000000 +0100
  2. +++ sed-4.1-jsaw/sed/execute.c 2004-06-24 13:35:57.497606648 +0200
  3. @@ -654,7 +654,7 @@
  4. input->read_fn = read_file_line;
  5. - if (in_place_extension)
  6. + if (in_place_extension && !(name[0] == '-' && name[1] == '\0'))
  7. {
  8. int output_fd;
  9. char *tmpdir = ck_strdup(name), *p;
  10. @@ -701,7 +701,7 @@
  11. if (input->fp != stdin) /* stdin can be reused on tty and tape devices */
  12. ck_fclose(input->fp);
  13. - if (in_place_extension && output_file.fp != NULL)
  14. + if (in_place_extension && output_file.fp != NULL && output_file.fp != stdout)
  15. {
  16. ck_fclose (output_file.fp);
  17. if (strcmp(in_place_extension, "*") != 0)