summaryrefslogtreecommitdiffstats
path: root/base/string_util.h
diff options
context:
space:
mode:
authorjungshik@google.com <jungshik@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-25 21:42:00 +0000
committerjungshik@google.com <jungshik@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-25 21:42:00 +0000
commitc9ec45429c64884c35f83b74131c0e3ae5b2bbe9 (patch)
tree39007373603b8e75f53fa5e4d0c1586b1a3a56b5 /base/string_util.h
parent7e2fa03804bef4bff9c5bb941f2edf09b6d234c0 (diff)
downloadchromium_src-c9ec45429c64884c35f83b74131c0e3ae5b2bbe9.zip
chromium_src-c9ec45429c64884c35f83b74131c0e3ae5b2bbe9.tar.gz
chromium_src-c9ec45429c64884c35f83b74131c0e3ae5b2bbe9.tar.bz2
Add UTF-8 check for JSON deserializer.
Add tests for IsStringUTF8 Make IsStringUTF8 accept std::string/std::wstring rather than char*/wchar_t* Review URL: http://codereview.chromium.org/4268 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2610 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/string_util.h')
-rw-r--r--base/string_util.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/base/string_util.h b/base/string_util.h
index 8c28f3b..a9f08c4 100644
--- a/base/string_util.h
+++ b/base/string_util.h
@@ -227,8 +227,8 @@ bool WideToLatin1(const std::wstring& wide, std::string* latin1);
// first case) or characters that use only 8-bits and whose 8-bit
// representation looks like a UTF-8 string (the second case).
bool IsString8Bit(const std::wstring& str);
-bool IsStringUTF8(const char* str);
-bool IsStringWideUTF8(const wchar_t* str);
+bool IsStringUTF8(const std::string& str);
+bool IsStringWideUTF8(const std::wstring& str);
bool IsStringASCII(const std::wstring& str);
bool IsStringASCII(const std::string& str);