]> git.mxchange.org Git - simgear.git/blobdiff - simgear/io/SVNReportParser.cxx
Reset: allow re-init of Nasal Ghosts.
[simgear.git] / simgear / io / SVNReportParser.cxx
index 96b357f51e3e231b05c23e8dd7e6cafac4592abc..b7f99d248fd369b29de21f26da5507b073b47a73 100644 (file)
@@ -392,7 +392,11 @@ public:
       finishFile(currentDir->addChildFile(currentPath.file()));
     } else if (!strcmp(name, SVN_OPEN_FILE_TAG)) {
       DAVResource* res = currentDir->collection()->childWithName(currentPath.file());   
-      assert(res);
+        if (!res) {
+            SG_LOG(SG_IO, SG_WARN, "SVN open-file: unknown: " << currentPath);
+            fail(SVNRepository::SVN_ERROR_IO);
+            return;
+        }
       finishFile(res);
     } else if (!strcmp(name, SVN_ADD_DIRECTORY_TAG)) {
       // pop directory
@@ -413,15 +417,16 @@ public:
     } else if (!strcmp(name, SVN_DAV_MD5_CHECKSUM)) {
       // validate against (presumably) just written file
       if (decodedFileMd5 != md5Sum) {
+          SG_LOG(SG_GENERAL, SG_INFO, "checksum fail on:" << currentPath);
         fail(SVNRepository::SVN_ERROR_CHECKSUM);
       }
     } else if (!strcmp(name, SVN_OPEN_DIRECTORY_TAG)) {
+        currentDir->updateReportComplete();
         if (currentDir->parent()) {   
           // pop the collection stack
           currentDir = currentDir->parent();
         }
         
-        currentDir->updateReportComplete();
         currentPath = currentDir->fsPath();
     } else {
     //  std::cout << "element:" << name;