Modify ↓
      
Opened 19 years ago
Closed 15 years ago
#3646 closed defect (wontfix)
Mime Viewer doesn't handle mixed line endings
| Reported by: | anonymous | Owned by: | Remy Blank | 
|---|---|---|---|
| Priority: | lowest | Milestone: | |
| Component: | general | Version: | devel | 
| Severity: | minor | Keywords: | patch renderer | 
| Cc: | Branch: | ||
| Release Notes: | |||
| API Changes: | |||
| Internal Changes: | |||
Description
Attached is a file that exhibits this behavior (note the line endings on the first 3 lines.
Attachments (1)
Change History (5)
by , 19 years ago
| Attachment: | sample.diff added | 
|---|
comment:1 by , 19 years ago
| Keywords: | patch renderer added | 
|---|---|
| Milestone: | → 1.0 | 
| Priority: | normal → lowest | 
| Severity: | normal → minor | 
comment:3 by , 15 years ago
| Milestone: | triaging → 0.13 | 
|---|---|
| Owner: | changed from to | 
comment:4 by , 15 years ago
| Milestone: | 0.13 | 
|---|---|
| Resolution: | → wontfix | 
| Status: | new → closed | 
I wouldn't consider sample.diff as having mixed line endings, but rather as having too many line endings. Here's the content as a Python string:
"Index: report/report_member_roster.asp\r\r\n" "===================================================================\r\r\n" "--- report/report_member_roster.asp\t(revision 192)\r\r\n" "+++ report/report_member_roster.asp\t(working copy)\r\r\n" "@@ -1,4 +1,4 @@\r\n" " This is a test file\r\n" "-That doesn't\r\n" "+That does not\r\n" " render\r\n" " correctly.\r\n"
The first four lines have duplicate line endings, so there's an empty line after each line, which is invalid syntax. Python does in fact handle mixed line endings very well:
>>> "111\n222\r333\r\n444".splitlines() ['111', '222', '333', '444']
So I'm closing this as "wontfix".
  Note:
 See   TracTickets
 for help on using tickets.
    


  
I hope this works