diff options
| author | Matthew Parlane <parlane@gmail.com> | 2014-03-10 09:24:09 +1300 |
|---|---|---|
| committer | Matthew Parlane <parlane@gmail.com> | 2014-03-10 09:24:09 +1300 |
| commit | 633dc75e857d649ffab7c4398e92536bccc9e1de (patch) | |
| tree | f9aa8831a0731ea246bd921d979f4bffa7f07bd0 /Source/Core/Common/StringUtil.cpp | |
| parent | f4012638672472afdbd9956229f273a18a77fd77 (diff) | |
| parent | d802d392811be44d34ae9cd23f616db93e54c50f (diff) | |
Merge pull request #142 from Tilka/clang-modernize
Run clang-modernize and manually fix the result
Diffstat (limited to 'Source/Core/Common/StringUtil.cpp')
| -rw-r--r-- | Source/Core/Common/StringUtil.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Source/Core/Common/StringUtil.cpp b/Source/Core/Common/StringUtil.cpp index 7f7ce5d794..1919083162 100644 --- a/Source/Core/Common/StringUtil.cpp +++ b/Source/Core/Common/StringUtil.cpp @@ -28,7 +28,7 @@ // faster than sscanf bool AsciiToHex(const char* _szValue, u32& result) { - char *endptr = NULL; + char *endptr = nullptr; const u32 value = strtoul(_szValue, &endptr, 16); if (!endptr || *endptr) @@ -66,7 +66,7 @@ bool CharArrayFromFormatV(char* out, int outsize, const char* format, va_list ar // will be present in the middle of a multibyte sequence. // // This is why we lookup an ANSI (cp1252) locale here and use _vsnprintf_l. - static locale_t c_locale = NULL; + static locale_t c_locale = nullptr; if (!c_locale) c_locale = _create_locale(LC_ALL, ".1252"); writtenCount = _vsnprintf_l(out, outsize, format, c_locale, args); @@ -89,7 +89,7 @@ bool CharArrayFromFormatV(char* out, int outsize, const char* format, va_list ar std::string StringFromFormat(const char* format, ...) { va_list args; - char *buf = NULL; + char *buf = nullptr; #ifdef _WIN32 int required = 0; @@ -159,7 +159,7 @@ std::string StripQuotes(const std::string& s) bool TryParse(const std::string &str, u32 *const output) { - char *endptr = NULL; + char *endptr = nullptr; // Reset errno to a value other than ERANGE errno = 0; |
