make sure we don't use uninitalized output stream in OnSysWrite() (coverity checked CID 7)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37884 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
37b6a42697
commit
10793ebfbb
@ -283,7 +283,11 @@ size_t wxZlibOutputStream::OnSysWrite(const void *buffer, size_t size)
|
||||
wxASSERT_MSG(m_deflate && m_z_buffer, wxT("Deflate stream not open"));
|
||||
|
||||
if (!m_deflate || !m_z_buffer)
|
||||
{
|
||||
m_lasterror = wxSTREAM_WRITE_ERROR;
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (!IsOk() || !size)
|
||||
return 0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user