(file) Return to String.cpp CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / Common

Diff for /pegasus/src/Pegasus/Common/String.cpp between version 1.119 and 1.119.2.3

version 1.119, 2006/01/30 16:17:08 version 1.119.2.3, 2007/02/07 21:06:04
Line 166 
Line 166 
 { {
 #ifndef PEGASUS_STRING_NO_THROW #ifndef PEGASUS_STRING_NO_THROW
  
     if (x > 0x0FFFFFFF)      // Check for potential overflow in x
         throw PEGASUS_STD(bad_alloc)();      PEGASUS_CHECK_CAPACITY_OVERFLOW(x);
  
 #endif #endif
  
Line 545 
Line 545 
 { {
 #ifndef PEGASUS_STRING_NO_THROW #ifndef PEGASUS_STRING_NO_THROW
  
     // Any string bigger than this is seriously suspect.      // Check for potential overflow in cap
     if (cap > 0x0FFFFFFF)      PEGASUS_CHECK_CAPACITY_OVERFLOW(cap);
         throw PEGASUS_STD(bad_alloc)();  
  
 #endif #endif
  
Line 843 
Line 842 
  
 String& String::append(const String& str) String& String::append(const String& str)
 { {
     return append((Char16*)str._rep->data, str._rep->size);      return append((Char16*)(&(str._rep->data[0])), str._rep->size);
 } }
  
 String& String::append(const char* str, Uint32 size) String& String::append(const char* str, Uint32 size)
Line 905 
Line 904 
         if (n == PEG_NOT_FOUND || n > _rep->size - index)         if (n == PEG_NOT_FOUND || n > _rep->size - index)
             n = _rep->size - index;             n = _rep->size - index;
  
         return String((Char16*)_rep->data + index, n);          return String((Char16*)(_rep->data + index), n);
     }     }
  
     return String();     return String();
Line 1137 
Line 1136 
     if (InitializeICU::initICUSuccessful())     if (InitializeICU::initICUSuccessful())
     {     {
         return  u_strcasecmp(         return  u_strcasecmp(
             str1._rep->data, str2._rep->data, U_FOLD_CASE_DEFAULT);              (const UChar*)str1._rep->data,
               (const UChar*)str2._rep->data,
               U_FOLD_CASE_DEFAULT
               );
     }     }
  
 #endif /* PEGASUS_HAS_ICU */ #endif /* PEGASUS_HAS_ICU */


Legend:
Removed from v.1.119  
changed lines
  Added in v.1.119.2.3

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2