Explorar o código

[apt-pkg/indexcopy.cc] fix a (hypothetical) memory leak then the Release
file not exists, patch from George Danchev, thanks! (Closes: #511556)

David Kalnischkies %!s(int64=17) %!d(string=hai) anos
pai
achega
cfb3d242de
Modificáronse 2 ficheiros con 6 adicións e 0 borrados
  1. 3 0
      apt-pkg/indexcopy.cc
  2. 3 0
      debian/changelog

+ 3 - 0
apt-pkg/indexcopy.cc

@@ -592,7 +592,10 @@ bool SigVerify::CopyAndVerify(string CDROM,string Name,vector<string> &SigList,
 
 
       // a Release.gpg without a Release should never happen
       // a Release.gpg without a Release should never happen
       if(!FileExists(*I+"Release"))
       if(!FileExists(*I+"Release"))
+      {
+	 delete MetaIndex;
 	 continue;
 	 continue;
+      }
 
 
 
 
       // verify the gpg signature of "Release"
       // verify the gpg signature of "Release"

+ 3 - 0
debian/changelog

@@ -8,6 +8,9 @@ apt (0.7.22.3) unstable; urgency=low
   * apt-pkg/contrib/strutl.cc:
   * apt-pkg/contrib/strutl.cc:
     - enable thousand separator according to the current locale
     - enable thousand separator according to the current locale
       (by Luca Bruno, Closes: #223712)
       (by Luca Bruno, Closes: #223712)
+  * apt-pkg/indexcopy.cc:
+    - fix a (hypothetical) memory leak then the Release file not exists
+      (by George Danchev, Closes: #511556)
 
 
  -- David Kalnischkies <david@kalnischkies.com>  Sat, 08 Aug 2009 09:40:08 +0200
  -- David Kalnischkies <david@kalnischkies.com>  Sat, 08 Aug 2009 09:40:08 +0200