From e3cd024e851b415857266a652b66bd9d89e36d84 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sun, 17 Oct 2010 13:59:48 +0000 Subject: [PATCH] Revert the changes of r65826 in wxConvertToGTK(). This is not necessary any longer after the previous commit which changed cMB2WC() to not return NULL for empty input. See #12432. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65837 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/gtk/utilsgtk.cpp | 6 ------ 1 file changed, 6 deletions(-) diff --git a/src/gtk/utilsgtk.cpp b/src/gtk/utilsgtk.cpp index 8e36cc40b7..93b8f02790 100644 --- a/src/gtk/utilsgtk.cpp +++ b/src/gtk/utilsgtk.cpp @@ -116,12 +116,6 @@ wxWindow* wxFindWindowAtPoint(const wxPoint& pt) WXDLLIMPEXP_CORE wxCharBuffer wxConvertToGTK(const wxString& s, wxFontEncoding enc) { - // Passing an empty string to cMB2WC() returns an invalid buffer, i.e. a - // buffer whose data is NULL and this can result in passing NULL to a GTK+ - // function and a crash, so handle this case specially to avoid this. - if ( s.empty() ) - return wxCharBuffer(""); - wxWCharBuffer wbuf; if ( enc == wxFONTENCODING_SYSTEM || enc == wxFONTENCODING_DEFAULT ) { -- 2.45.2