* fix segfault when there is no Archive for a VerFile
authorMichael Vogt <michael.vogt@ubuntu.com>
Wed, 19 Oct 2005 12:34:19 +0000 (12:34 +0000)
committerMichael Vogt <michael.vogt@ubuntu.com>
Wed, 19 Oct 2005 12:34:19 +0000 (12:34 +0000)
cmdline/apt-get.cc

index 82f2021..3ffb740 100644 (file)
@@ -1227,7 +1227,7 @@ pkgSrcRecords::Parser *FindSrc(const char *Name,pkgRecords &Recs,
            continue;
            
            //std::cout << VF.File().Archive() << std::endl;
-           if(VF.File().Archive() == DefRel
+           if(VF.File().Archive() && (VF.File().Archive() == DefRel)
            {
               VerTag = Ver.VerStr();
               break;