diff options
author | Max Horn | 2002-09-28 19:25:09 +0000 |
---|---|---|
committer | Max Horn | 2002-09-28 19:25:09 +0000 |
commit | 94b55db8215e709a40cc562df3d8e1540e6b5174 (patch) | |
tree | 27c59541d7f9dc98f8af3635aff2fbe6ffe5c51e /common/str.cpp | |
parent | 9dc5fe2a1dc4196d5785b484bfb1a96d33d732e8 (diff) | |
download | scummvm-rg350-94b55db8215e709a40cc562df3d8e1540e6b5174.tar.gz scummvm-rg350-94b55db8215e709a40cc562df3d8e1540e6b5174.tar.bz2 scummvm-rg350-94b55db8215e709a40cc562df3d8e1540e6b5174.zip |
patch #612722: MI2 NewGui title fix
svn-id: r5030
Diffstat (limited to 'common/str.cpp')
-rw-r--r-- | common/str.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/common/str.cpp b/common/str.cpp index 874b99938e..7b33b29c30 100644 --- a/common/str.cpp +++ b/common/str.cpp @@ -20,13 +20,10 @@ #include "stdafx.h" #include "str.h" -#include "util.h" #ifdef _MSC_VER - # pragma warning( disable : 4068 ) // unknown pragmas - #endif @@ -39,7 +36,7 @@ String::String(const char *str, int len) if (len > 0) _capacity = _len = len; else - _capacity = _len = resStrLen(str); + _capacity = _len = strlen(str); _str = (char *)calloc(1, _capacity+1); memcpy(_str, str, _len); _str[_len] = 0; @@ -54,7 +51,7 @@ String::String(const ConstString &str) printf("String::String(const ConstString &str)\n"); _refCount = new int(1); if (str._str) { - _capacity = _len = resStrLen(str._str); + _capacity = _len = strlen(str._str); _str = (char *)calloc(1, _capacity+1); memcpy(_str, str._str, _len+1); } else { @@ -90,7 +87,7 @@ void String::decRefCount() String& String::operator =(const char* str) { - int len = resStrLen(str); + int len = strlen(str); if (len > 0) { ensureCapacity(len, false); @@ -123,7 +120,7 @@ String& String::operator =(const String& str) String& String::operator +=(const char* str) { - int len = resStrLen(str); + int len = strlen(str); if (len > 0) { ensureCapacity(_len + len, true); |