From: Vadim Zeitlin Date: Fri, 30 Nov 2007 14:41:05 +0000 (+0000) Subject: fix an unused variable warning in release build X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/7a8dce715f3cbe7f7289ab02b4854993f92c981f?ds=sidebyside fix an unused variable warning in release build git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@50353 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/msw/listctrl.cpp b/src/msw/listctrl.cpp index 6f22017cff..1ba0251cdf 100644 --- a/src/msw/listctrl.cpp +++ b/src/msw/listctrl.cpp @@ -2821,8 +2821,10 @@ void wxListCtrl::OnPaint(wxPaintEvent& event) int numCols = GetColumnCount(); int* indexArray = new int[numCols]; - BOOL rv = ListView_GetColumnOrderArray( GetHwnd(), numCols, indexArray ); - wxASSERT_MSG( rv == TRUE, _T("invalid column index array in OnPaint()") ); + if ( !ListView_GetColumnOrderArray( GetHwnd(), numCols, indexArray) ) + { + wxFAIL_MSG( _T("invalid column index array in OnPaint()") ); + } int x = itemRect.GetX(); for (int col = 0; col < numCols; col++)