From: Vadim Zeitlin Date: Thu, 6 Nov 2008 23:31:26 +0000 (+0000) Subject: check for NULL pointer in IsExtensionInList() X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/442e842ee73186ff17b89d434b2a434245bc68e8?ds=sidebyside check for NULL pointer in IsExtensionInList() git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@56692 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/common/glcmn.cpp b/src/common/glcmn.cpp index b3e1f57502..4f5f9c6025 100644 --- a/src/common/glcmn.cpp +++ b/src/common/glcmn.cpp @@ -118,6 +118,9 @@ void wxGLCanvasBase::OnSize(wxSizeEvent& WXUNUSED(event)) /* static */ bool wxGLCanvasBase::IsExtensionInList(const char *list, const char *extension) { + if ( !list ) + return false; + for ( const char *p = list; *p; p++ ) { // advance up to the next possible match