Bug 27483

Summary: diff_parser should accept lines without trailing \n
Product: WebKit Reporter: Shinichiro Hamaji <hamaji>
Component: Tools / TestsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: levin
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: OS X 10.5   
Attachments:
Description Flags
Patch v1 levin: review+

Description Shinichiro Hamaji 2009-07-20 23:10:18 PDT
It would be better to normalize the input lines by removing trailing newlines to accept both patch.splitlines() and file object.
Comment 1 Shinichiro Hamaji 2009-07-20 23:14:08 PDT
Created attachment 33145 [details]
Patch v1


---
 3 files changed, 29 insertions(+), 2 deletions(-)
Comment 2 David Levin 2009-07-20 23:50:07 PDT
Comment on attachment 33145 [details]
Patch v1

> diff --git a/WebKitTools/ChangeLog b/WebKitTools/ChangeLog

> +
> +        Normalize the input lines by removing a trailing newline.
> +        Also, add a case for unittest for newly added files.
I think this reads better: "Also, add a case to the unittest for newly added files."

fwiw, it is best to keep your patches focused on one thing and this does a bit more, so the bug doesn't reflect what is being done. However, it is all rather simple and you do describe it, so no need to break it up this time.
Comment 3 David Levin 2009-07-21 03:13:15 PDT
Committed as http://trac.webkit.org/changeset/46164