Uploaded image for project: 'rosapps SVN Repository'
  1. rosapps SVN Repository
  2. ROSAPPS-222

PATCH: Incorrect overwrite behaviour in cmdutils/tee

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • None
    • Utilities
    • None
    • Operating System: ReactOS
      Platform: x86 Hardware

    Description

      Created an attachment (id=5973)
      corrects overwrites in cmdutils/tee

      When executing tee,
      it doesn't truncate output files before writing.

      Example:
      <name> <size>
      file1 100
      file2 300

      cat file1 | tee file2

      Result:
      file1 100
      file2 300 (100 first bytes overwritten by contents of file1).

      must be:
      file1 100
      file2 100

      In NT and UNIX versions of tee truncation is implemented.
      Also POSIX-2001 standard tells that standard input
      must be copied to each of the files, including stdout (truncate and write).

      I've attached diff-patch.

      Attachments

        Activity

          People

            bug zilla Bug Zilla
            kruntuid kruntuid
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: