[csw-devel] SF.net SVN: gar:[17901] csw/mgar/gar/v2/lib/python/inspective_package.py

wahwah at users.sourceforge.net wahwah at users.sourceforge.net
Mon Apr 30 09:14:44 CEST 2012


Revision: 17901
          http://gar.svn.sourceforge.net/gar/?rev=17901&view=rev
Author:   wahwah
Date:     2012-04-30 07:14:44 +0000 (Mon, 30 Apr 2012)
Log Message:
-----------
checkpkg: bugfix:Remove tmp bits from binary paths

The temporary directory names were leaking into the indexed data.

Context:
http://lists.opencsw.org/pipermail/maintainers/2012-April/016496.html

Modified Paths:
--------------
    csw/mgar/gar/v2/lib/python/inspective_package.py

Modified: csw/mgar/gar/v2/lib/python/inspective_package.py
===================================================================
--- csw/mgar/gar/v2/lib/python/inspective_package.py	2012-04-30 07:14:24 UTC (rev 17900)
+++ csw/mgar/gar/v2/lib/python/inspective_package.py	2012-04-30 07:14:44 UTC (rev 17901)
@@ -88,13 +88,13 @@
       self.files_metadata = []
       files_root = self.GetFilesDir()
       all_files = self.GetAllFilePaths()
-      def StripRe(x, strip_re):
-        return re.sub(strip_re, "", x)
       file_magic = FileMagic()
       basedir = self.GetBasedir()
       for file_path in all_files:
         full_path = unicode(self.MakeAbsolutePath(file_path))
         file_info = GetFileMetadata(file_magic, self.pkgpath, full_path)
+        # To prevent files from containing the full temporary path.
+        file_info["path"] = StripRe(file_path, ROOT_RE)
         self.files_metadata.append(file_info)
     return self.files_metadata
 

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



More information about the devel mailing list