Windows compilation fixes after recent changes

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16785 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2002-08-25 19:03:06 +00:00
parent bdaac0eba9
commit 129db666f1
2 changed files with 11 additions and 11 deletions

View File

@@ -643,17 +643,17 @@ WXDLLEXPORT bool wxOKlibc(); // for internal use
int wxVfprintf( FILE *stream, const wxChar *format, va_list ap ); int wxVfprintf( FILE *stream, const wxChar *format, va_list ap );
int wxVprintf( const wxChar *format, va_list ap ); int wxVprintf( const wxChar *format, va_list ap );
int wxVsprintf( wxChar *str, const wxChar *format, va_list ap ); int wxVsprintf( wxChar *str, const wxChar *format, va_list ap );
#endif // wxNEED_PRINTF_CONVERSION
// these 2 can be simply mapped to the versions with underscore at the end // these 2 can be simply mapped to the versions with underscore at the end
// if we don't have to do the conversion // if we don't have to do the conversion
#ifdef wxNEED_PRINTF_CONVERSION #ifdef wxNEED_PRINTF_CONVERSION
int wxSnprintf( wxChar *str, size_t size, const wxChar *format, ... ) ATTRIBUTE_PRINTF_4; int wxSnprintf( wxChar *str, size_t size, const wxChar *format, ... ) ATTRIBUTE_PRINTF_4;
int wxVsnprintf( wxChar *str, size_t size, const wxChar *format, va_list ap ); int wxVsnprintf( wxChar *str, size_t size, const wxChar *format, va_list ap );
#else #else
#define wxSnprintf wxSnprintf_ #define wxSnprintf wxSnprintf_
#define wxVsnprintf wxVsnprintf_ #define wxVsnprintf wxVsnprintf_
#endif #endif
#endif // wxNEED_PRINTF_CONVERSION
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// various functions which might not be available in libc and for which we // various functions which might not be available in libc and for which we

View File

@@ -244,7 +244,7 @@ const wxCharBuffer wxMBConv::cWC2MB(const wchar_t *pwz) const
// return value excludes NUL // return value excludes NUL
size_t nLen = pwz ? WC2MB((char *) NULL, pwz, 0) : (size_t)-1; size_t nLen = pwz ? WC2MB((char *) NULL, pwz, 0) : (size_t)-1;
if (nLen == (size_t)-1) if (nLen == (size_t)-1)
return wxCharBuffer(NULL); return wxCharBuffer((const char *)NULL);
wxCharBuffer buf(nLen); // this allocates nLen+1 wxCharBuffer buf(nLen); // this allocates nLen+1
WC2MB((char *)(const char *) buf, pwz, nLen+1); WC2MB((char *)(const char *) buf, pwz, nLen+1);