projects
/
platform
/
framework
/
web
/
crosswalk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Update To 11.40.268.0
[platform/framework/web/crosswalk.git]
/
src
/
third_party
/
WebKit
/
Source
/
wtf
/
text
/
TextEncodingRegistry.cpp
diff --git
a/src/third_party/WebKit/Source/wtf/text/TextEncodingRegistry.cpp
b/src/third_party/WebKit/Source/wtf/text/TextEncodingRegistry.cpp
index
66b5756
..
bf917b3
100644
(file)
--- a/
src/third_party/WebKit/Source/wtf/text/TextEncodingRegistry.cpp
+++ b/
src/third_party/WebKit/Source/wtf/text/TextEncodingRegistry.cpp
@@
-274,8
+274,8
@@
const char* atomicCanonicalTextEncodingName(const CharacterType* characters, siz
char buffer[maxEncodingNameLength + 1];
size_t j = 0;
for (size_t i = 0; i < length; ++i) {
char buffer[maxEncodingNameLength + 1];
size_t j = 0;
for (size_t i = 0; i < length; ++i) {
-
CharacterType c = characters[i]
;
- if (j == maxEncodingNameLength)
+
char c = static_cast<char>(characters[i])
;
+ if (j == maxEncodingNameLength
|| c != characters[i]
)
return 0;
buffer[j++] = c;
}
return 0;
buffer[j++] = c;
}
@@
-296,7
+296,7
@@
const char* atomicCanonicalTextEncodingName(const String& alias)
bool noExtendedTextEncodingNameUsed()
{
bool noExtendedTextEncodingNameUsed()
{
- // If the calling thread did not use extended encoding names, it is fine for it to use a stale false value.
+ MutexLocker lock(encodingRegistryMutex());
return !didExtendTextCodecMaps;
}
return !didExtendTextCodecMaps;
}