Bug 213452

Summary: [Win] fast/dom/Window/alert-with-unmatched-utf16-surrogate-should-not-crash.html is failing
Product: WebKit Reporter: Fujii Hironori <Hironori.Fujii>
Component: Tools / TestsAssignee: Fujii Hironori <Hironori.Fujii>
Status: RESOLVED FIXED    
Severity: Normal CC: darin, don.olmstead, pvollan, ross.kirsling, webkit-bug-importer, ysuzuki
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
none
Patch
none
Patch none

Description Fujii Hironori 2020-06-21 21:29:58 PDT
[Win][WTR] fast/dom/Window/alert-with-unmatched-utf16-surrogate-should-not-crash.html is failing

Since it was added in Bug 213269.
Comment 1 Fujii Hironori 2020-06-21 21:39:13 PDT
Created attachment 402443 [details]
Patch
Comment 2 Fujii Hironori 2020-06-21 21:40:13 PDT
Created attachment 402444 [details]
Patch
Comment 3 Fujii Hironori 2020-06-21 22:04:02 PDT
Created attachment 402445 [details]
Patch
Comment 4 Darin Adler 2020-06-22 08:07:37 PDT
Comment on attachment 402445 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=402445&action=review

> Tools/DumpRenderTree/win/UIDelegate.cpp:458
> +    // Return "(null)" for an invalid UTF-16 sequence

Why not “invalid”? Not sure why we call an invalid sequence null.
Comment 5 Fujii Hironori 2020-06-22 12:27:48 PDT
Comment on attachment 402445 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=402445&action=review

>> Tools/DumpRenderTree/win/UIDelegate.cpp:458
>> +    // Return "(null)" for an invalid UTF-16 sequence
> 
> Why not “invalid”? Not sure why we call an invalid sequence null.

WinCairo is supporting both WK1 and WK2. DRT should behave same with WTR. See Bug 213269 for WTR.
Comment 6 Darin Adler 2020-06-22 12:35:49 PDT
Then the comment should say why. Generally speaking, comments purpose is to answer the question "why". The code itself answers the question "what".
Comment 7 Fujii Hironori 2020-06-22 12:40:22 PDT
Created attachment 402495 [details]
Patch
Comment 8 Fujii Hironori 2020-06-22 12:43:09 PDT
(In reply to Darin Adler from comment #6)
> Then the comment should say why. Generally speaking, comments purpose is to
> answer the question "why". The code itself answers the question "what".

Agreed. Fixed. Thank you.
Comment 9 Yusuke Suzuki 2020-06-22 17:36:13 PDT
Comment on attachment 402495 [details]
Patch

Nice!
Comment 10 Fujii Hironori 2020-06-22 18:23:39 PDT
Comment on attachment 402495 [details]
Patch

Clearing flags on attachment: 402495

Committed r263379: <https://trac.webkit.org/changeset/263379>
Comment 11 Fujii Hironori 2020-06-22 18:23:43 PDT
All reviewed patches have been landed.  Closing bug.
Comment 12 Radar WebKit Bug Importer 2020-06-22 18:24:21 PDT
<rdar://problem/64618144>