1 |
Author: zmedico |
2 |
Date: 2010-03-02 19:49:24 +0000 (Tue, 02 Mar 2010) |
3 |
New Revision: 15528 |
4 |
|
5 |
Modified: |
6 |
main/branches/2.1.7/pym/portage/manifest.py |
7 |
Log: |
8 |
Fix concatenation of list + tuple in Manifest._createManifestEntries(). |
9 |
(trunk r15289) |
10 |
|
11 |
Modified: main/branches/2.1.7/pym/portage/manifest.py |
12 |
=================================================================== |
13 |
--- main/branches/2.1.7/pym/portage/manifest.py 2010-03-02 19:49:17 UTC (rev 15527) |
14 |
+++ main/branches/2.1.7/pym/portage/manifest.py 2010-03-02 19:49:24 UTC (rev 15528) |
15 |
@@ -205,6 +205,8 @@ |
16 |
return myhashdict |
17 |
|
18 |
def _createManifestEntries(self): |
19 |
+ valid_hashes = set(portage.const.MANIFEST2_HASH_FUNCTIONS) |
20 |
+ valid_hashes.add('size') |
21 |
mytypes = list(self.fhashdict) |
22 |
mytypes.sort() |
23 |
for t in mytypes: |
24 |
@@ -213,10 +215,8 @@ |
25 |
for f in myfiles: |
26 |
myentry = Manifest2Entry( |
27 |
type=t, name=f, hashes=self.fhashdict[t][f].copy()) |
28 |
- myhashkeys = list(myentry.hashes) |
29 |
- myhashkeys.sort() |
30 |
- for h in myhashkeys: |
31 |
- if h not in ["size"] + portage.const.MANIFEST2_HASH_FUNCTIONS: |
32 |
+ for h in list(myentry.hashes): |
33 |
+ if h not in valid_hashes: |
34 |
del myentry.hashes[h] |
35 |
yield myentry |