lmi
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lmi] '-Wconversion-null' warning with latest wx and i686 gcc-8.3


From: Vadim Zeitlin
Subject: Re: [lmi] '-Wconversion-null' warning with latest wx and i686 gcc-8.3
Date: Wed, 22 Jul 2020 16:35:33 +0200

On Wed, 22 Jul 2020 14:10:39 +0000 Greg Chicares <gchicares@sbcglobal.net> 
wrote:

GC> This is probably benign, but I'll report it anyway.

 Thanks, somehow I hadn't noticed this neither. It is, of course, benign,
but should be fixed anyhow, especially as it's simple to do:

---------------------------------- >8 --------------------------------------
diff --git a/src/msw/listbox.cpp b/src/msw/listbox.cpp
index 4ccef0529f..3291792888 100644
--- a/src/msw/listbox.cpp
+++ b/src/msw/listbox.cpp
@@ -617,7 +617,7 @@ void wxListBox::SetHorizontalExtent(const wxString& s)
 bool wxListBox::MSWSetTabStops(const wxVector<int>& tabStops)
 {
     return SendMessage(GetHwnd(), LB_SETTABSTOPS, (WPARAM)tabStops.size(),
-                       tabStops.empty() ? NULL : (LPARAM)&tabStops[0]) == TRUE;
+                       (LPARAM)(tabStops.empty() ? NULL : &tabStops[0])) == 
TRUE;
 }

 wxSize wxListBox::DoGetBestClientSize() const
---------------------------------- >8 --------------------------------------

I'll push this once 3.1.4 is officially announced and done.

 And I also plan to set up a wxMSW CI build using MinGW-w64 with -Werror
which will catch any such problems in the future.

 Thanks again for reporting this one,
VZ

Attachment: pgpoLR7ptziXs.pgp
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]