diff options
author | George Hazan <ghazan@miranda.im> | 2021-11-14 22:02:48 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2021-11-14 22:02:48 +0300 |
commit | d27df9286f2f8b6df5713c756244c83f2585f53e (patch) | |
tree | 4a12246e83c46dd7b7d8b39316edf11d4dbd36a8 /include | |
parent | 580af48389fb3f05663b5e28e41a69ca518b9e0f (diff) |
compilation fix
Diffstat (limited to 'include')
-rw-r--r-- | include/m_string.inl | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/include/m_string.inl b/include/m_string.inl index 18498889ee..5d88876756 100644 --- a/include/m_string.inl +++ b/include/m_string.inl @@ -25,7 +25,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #ifndef M_STRING_INL__ -#include <algorithm> +#ifndef _MSC_VER + #include <algorithm> + #define __max std::max +#endif template<typename BaseType> CMSimpleStringT<BaseType>::CMSimpleStringT() @@ -853,7 +856,7 @@ int CMStringT<BaseType, StringTraits>::Replace(PCXSTR pszOld, PCXSTR pszNew) int nOldLength = this->GetLength(); int nNewLength = nOldLength + (nReplacementLen - nSourceLen)*nCount; - PXSTR pszBuffer = this->GetBuffer(std::max(nNewLength, nOldLength)); + PXSTR pszBuffer = this->GetBuffer(__max(nNewLength, nOldLength)); PXSTR pszStart = pszBuffer; PXSTR pszEnd = pszStart + nOldLength; |