X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/823e82e260a80c0e7e15636e1f8da1f9da08c654..7198c3368055d88249a338eb33b21f051f674806:/src/common/convauto.cpp?ds=inline diff --git a/src/common/convauto.cpp b/src/common/convauto.cpp index dde8af743e..8620d4e02e 100644 --- a/src/common/convauto.cpp +++ b/src/common/convauto.cpp @@ -23,12 +23,6 @@ #pragma hdrstop #endif -#if wxUSE_WCHAR_T - -#ifndef WX_PRECOMP - #include "wx/wx.h" -#endif //WX_PRECOMP - #include "wx/convauto.h" // we use latin1 by default as it seems the least bad choice: the files we need @@ -231,7 +225,7 @@ void wxConvAuto::SkipBOM(const char **src, size_t *len) const bool wxConvAuto::InitFromInput(const char *src, size_t len) { - m_bomType = DetectBOM(src, len); + m_bomType = DetectBOM(src, len == wxNO_LEN ? strlen(src) : len); if ( m_bomType == BOM_Unknown ) return false; @@ -318,5 +312,3 @@ wxConvAuto::FromWChar(char *dst, size_t dstLen, return m_conv->FromWChar(dst, dstLen, src, srcLen); } - -#endif // wxUSE_WCHAR_T