Update CSplitString (#267)

This commit is contained in:
Poggu authored and GitHub committed 2024-10-03 16:55:30 +03:00
1 parent d2709c880c
commit ffbc15d41e
1 file changed
+3 -3
+3 -3
View File
@@ -1196,12 +1196,12 @@ class CSplitString: public CUtlVector<char*, CUtlMemory<char*, int> >
public:
CSplitString(const char *pString, const char *pSeparator, bool bIncludeSeparators = false)
{
Construct( pString, &pSeparator, 1, bIncludeSeparators);
Split( pString, 0, &pSeparator, 1, bIncludeSeparators);
}
CSplitString(const char *pString, const char **pSeparators, int nSeparators, bool bIncludeSeparators = false)
{
Construct(pString, pSeparators, nSeparators, bIncludeSeparators);
Split(pString, 0, pSeparators, nSeparators, bIncludeSeparators);
}
~CSplitString()
@@ -1214,7 +1214,7 @@ public:
// NOTE: If you want to make Construct() public and implement Purge() here, you'll have to free m_szBuffer there
//
private:
DLL_CLASS_IMPORT void Construct(const char *pString, const char **pSeparators, int nSeparators, bool bIncludeSeparators);
DLL_CLASS_IMPORT void Split(const char *pString, int stringSize, const char **pSeparators, int nSeparators, bool bIncludeSeparators);
void PurgeAndDeleteElements()
{