X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/348a9a6ff24ab84a35d730ba2d5b27eb7f53b80c..a386b9c6142df7631e160063a7b92995488b5e3e:/src/html/chm.cpp diff --git a/src/html/chm.cpp b/src/html/chm.cpp index 195e7b9a95..954bd46490 100644 --- a/src/html/chm.cpp +++ b/src/html/chm.cpp @@ -563,7 +563,6 @@ void wxChmInputStream::CreateHHPStream() { wxFileName file; - bool topic = false; bool hhc = false; bool hhk = false; wxInputStream *i; @@ -631,7 +630,6 @@ wxChmInputStream::CreateHHPStream() break; case 2: // DEFAULT_TOPIC tmp = "Default Topic="; - topic = true; break; case 3: // TITLE tmp = "Title="; @@ -842,6 +840,8 @@ wxFSFile* wxChmFSHandler::OpenFile(wxFileSystem& WXUNUSED(fs), } wxFileName leftFilename = wxFileSystem::URLToFileName(left); + if (!leftFilename.FileExists()) + return NULL; // Open a stream to read the content of the chm-file s = new wxChmInputStream(leftFilename.GetFullPath(), right, true);