]> git.saurik.com Git - wxWidgets.git/commitdiff
Fixed Cygwin crash on toolbar tooltip
authorMattia Barbon <mbarbon@cpan.org>
Mon, 19 Nov 2001 18:58:04 +0000 (18:58 +0000)
committerMattia Barbon <mbarbon@cpan.org>
Mon, 19 Nov 2001 18:58:04 +0000 (18:58 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12489 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/msw/tbar95.cpp

index 6ea1b236f477feddcdee879b642010717b75e2f5..40119dce3bd8017efd824ea887c1b0616fcb90ac 100644 (file)
@@ -836,8 +836,9 @@ bool wxToolBar::MSWOnNotify(int WXUNUSED(idCtrl),
             //     this case
 
             size_t lenAnsi = help.Len();
             //     this case
 
             size_t lenAnsi = help.Len();
-            #ifdef __MWERKS__
+            #if defined( __MWERKS__ ) || defined( __CYGWIN__ )
                 // MetroWerks doesn't like calling mbstowcs with NULL argument
                 // MetroWerks doesn't like calling mbstowcs with NULL argument
+                // neither Cygwin does
                 size_t lenUnicode = 2*lenAnsi;
             #else
                 size_t lenUnicode = mbstowcs(NULL, help, lenAnsi);
                 size_t lenUnicode = 2*lenAnsi;
             #else
                 size_t lenUnicode = mbstowcs(NULL, help, lenAnsi);