RESOLVED FIXED 108791
Support setLangAttributeAwareFormControlUIEnabled on Chromium Windows XP
https://bugs.webkit.org/show_bug.cgi?id=108791
Summary Support setLangAttributeAwareFormControlUIEnabled on Chromium Windows XP
Kent Tamura
Reported 2013-02-03 22:14:00 PST
Support setLangAttributeAwareFormControlUIEnabled on Chromium Windows
Attachments
Patch (8.59 KB, patch)
2013-02-03 22:24 PST, Kent Tamura
haraken: review+
Kent Tamura
Comment 1 2013-02-03 22:24:51 PST
Kentaro Hara
Comment 2 2013-02-03 22:40:48 PST
Comment on attachment 186307 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=186307&action=review > Source/WebCore/platform/text/win/LocaleWin.cpp:71 > +static void initializeNameToLCIDMapIfEmpty(NameToLCIDMap& map) ensureNameToLCIDMap() ? (I'm not sure of naming convention around here though.) > Source/WebCore/platform/text/win/LocaleWin.cpp:108 > + if (!name || !name[0]) Is it safe to access name[0] without checking name.length ? > Source/WebCore/platform/text/win/LocaleWin.cpp:136 > - return LOCALE_USER_DEFAULT; > + localeNameToLCID = convertLocaleNameToLCID; Is it OK to fall through the code when localeNameToLCID is LOCALE_USER_DEFAULT ?
Kent Tamura
Comment 3 2013-02-03 22:47:40 PST
Comment on attachment 186307 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=186307&action=review >> Source/WebCore/platform/text/win/LocaleWin.cpp:108 >> + if (!name || !name[0]) > > Is it safe to access name[0] without checking name.length ? Yes, it is. We have no ways to check length of 'name' because it is null-terminated string. >> Source/WebCore/platform/text/win/LocaleWin.cpp:136 >> + localeNameToLCID = convertLocaleNameToLCID; > > Is it OK to fall through the code when localeNameToLCID is LOCALE_USER_DEFAULT ? Yes. localeNameToLCID is a function pointer, and convertLocaleNameToLCID and LocaleNameToLCID are compatible.
Kentaro Hara
Comment 4 2013-02-03 22:48:24 PST
Comment on attachment 186307 [details] Patch thanks for clarification!
Kent Tamura
Comment 5 2013-02-03 22:59:42 PST
Note You need to log in before you can comment on or make changes to this bug.