Changeset 79830 in webkit


Ignore:
Timestamp:
Feb 27, 2011 1:51:08 PM (13 years ago)
Author:
Adam Roben
Message:

Use iswalpha instead of isalpha when dealing with wchar_ts in EditingDelegate

Fixes <http://webkit.org/b/55062> <rdar://problem/9059907> Crash beneath
EditingDelegate::checkSpellingOfString when running fast/forms/input-text-maxlength.html or
fast/forms/input-text-paste-maxlength.html on Windows with full page heap enabled

Reviewed by Anders Carlsson.

  • DumpRenderTree/win/EditingDelegate.cpp:

(indexOfFirstWordCharacter):
(wordLength):
Use iswalpha instead of isalpha, since TCHAR is really just wchar_t.

Location:
trunk/Tools
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/ChangeLog

    r79827 r79830  
     12011-02-27  Adam Roben  <aroben@apple.com>
     2
     3        Use iswalpha instead of isalpha when dealing with wchar_ts in EditingDelegate
     4
     5        Fixes <http://webkit.org/b/55062> <rdar://problem/9059907> Crash beneath
     6        EditingDelegate::checkSpellingOfString when running fast/forms/input-text-maxlength.html or
     7        fast/forms/input-text-paste-maxlength.html on Windows with full page heap enabled
     8
     9        Reviewed by Anders Carlsson.
     10
     11        * DumpRenderTree/win/EditingDelegate.cpp:
     12        (indexOfFirstWordCharacter):
     13        (wordLength):
     14        Use iswalpha instead of isalpha, since TCHAR is really just wchar_t.
     15
    1162011-02-27  Adam Roben  <aroben@apple.com>
    217
  • trunk/Tools/DumpRenderTree/win/EditingDelegate.cpp

    r70291 r79830  
    358358{
    359359    const TCHAR* cursor = text;
    360     while (*cursor && !isalpha(*cursor))
     360    while (*cursor && !iswalpha(*cursor))
    361361        ++cursor;
    362362    return *cursor ? (cursor - text) : -1;
     
    366366{
    367367    const TCHAR* cursor = text;
    368     while (*cursor && isalpha(*cursor))
     368    while (*cursor && iswalpha(*cursor))
    369369        ++cursor;
    370370    return cursor - text;
Note: See TracChangeset for help on using the changeset viewer.