Uploaded image for project: 'Subversion'
  1. Subversion
  2. SVN-2796

"svn diff" regards CR (^M) as EOL under Unix

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.4.x
    • unscheduled
    • libsvn_diff
    • None

    Description

      Under Unix (both Mac OS X and Linux, with svn 1.4.3 and 1.4.4 respectively), svn
      regards the CR (^M) character as an end-of-line, though the svn:eol-style
      property isn't set.
      
      To reproduce this bug, commit file diff-cr-bug1 (will be attached). Then do "svn
      cp diff-cr-bug1 diff-cr-bug2" and modify diff-cr-bug2 according to the attachment.
      
      "svn diff diff-cr-bug2 | less" shows the bug:
      
      Index: diff-cr-bug2
      ===================================================================
      --- diff-cr-bug2        (revision 17290)
      +++ diff-cr-bug2        (working copy)
      @@ -1,5 +1,5 @@
       1^M-a
      +aa
       2^M b
       3^M@@ -9,7 +9,8 @@
       5^M e
       6^M-f
      +f^M+f
       7^M g
       8
      
      while "svn diff --diff-cmd `which diff` diff-cr-bug2 | less" shows that the
      system diff behaves correctly:
      
      Index: diff-cr-bug2
      ===================================================================
      --- diff-cr-bug2        (revision 17290)
      +++ diff-cr-bug2        (working copy)
      @@ -1,9 +1,9 @@
      -1^Ma
      +1^Maa
       2^Mb
       3^Mc
       4^Md
       5^Me
      -6^Mf
      +6^Mf^Mf
       7^Mg
       8^Mh
       9^Mi
      

      http://subversion.tigris.org/servlets/ReadMsg?list=dev&msgNo=126898

      Attachments

        1. 4_svn-no-lr-newlines.diff
          0.8 kB
          Stefan Sperling
        2. 3_recipe.sh
          0.4 kB
          Stefan Sperling
        3. 2_diff-cr-bug2.txt
          0.0 kB
          Vincent Lefevre
        4. 1_diff-cr-bug1.txt
          0.0 kB
          Vincent Lefevre

        Activity

          People

            Unassigned Unassigned
            vinc17 Vincent Lefevre
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: