Backed out changeset 8a4595cc5ec4 for Linux build failure on a CLOESD TREE

just kidding it's a CLOSED TREE
This commit is contained in:
David Major
2014-11-12 17:19:15 +13:00
parent be63b73148
commit 4954e07571
7 changed files with 26 additions and 39 deletions

View File

@@ -386,7 +386,7 @@ nsTString_CharT::SetCharAt( char16_t aChar, uint32_t aIndex )
return false;
if (!EnsureMutable())
AllocFailed(mLength);
NS_ABORT_OOM(mLength);
mData[aIndex] = CharT(aChar);
return true;
@@ -401,7 +401,7 @@ void
nsTString_CharT::StripChars( const char* aSet )
{
if (!EnsureMutable())
AllocFailed(mLength);
NS_ABORT_OOM(mLength);
mLength = nsBufferRoutines<CharT>::strip_chars(mData, mLength, aSet);
}
@@ -421,7 +421,7 @@ void
nsTString_CharT::ReplaceChar( char_type aOldChar, char_type aNewChar )
{
if (!EnsureMutable()) // XXX do this lazily?
AllocFailed(mLength);
NS_ABORT_OOM(mLength);
for (uint32_t i=0; i<mLength; ++i)
{
@@ -434,7 +434,7 @@ void
nsTString_CharT::ReplaceChar( const char* aSet, char_type aNewChar )
{
if (!EnsureMutable()) // XXX do this lazily?
AllocFailed(mLength);
NS_ABORT_OOM(mLength);
char_type* data = mData;
uint32_t lenRemaining = mLength;