X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/cffff062b34764a1b0978a06cf3788403cd73f3b..c12822fec7f87e7734cabbfcf23b99685fc371ce:/src/xrc/xmlres.cpp diff --git a/src/xrc/xmlres.cpp b/src/xrc/xmlres.cpp index fc16e6ec42..ae88b74358 100644 --- a/src/xrc/xmlres.cpp +++ b/src/xrc/xmlres.cpp @@ -497,7 +497,7 @@ bool wxXmlResource::UpdateResources() delete rec->Doc; rec->Doc = new wxXmlDocument; } - if (!stream || !rec->Doc->Load(*stream, encoding)) + if (!stream || !stream->IsOk() || !rec->Doc->Load(*stream, encoding)) { wxLogError(_("Cannot load resources from file '%s'."), rec->File);