[game-data-packager] 01/17: GameData: do not crash if _iter_expand_groups changes self.files

Simon McVittie smcv at debian.org
Wed Dec 30 22:57:17 UTC 2015


This is an automated email from the git hooks/post-receive script.

smcv pushed a commit to branch master
in repository game-data-packager.

commit bfcdfa54a300e851c1acdf970a89a65d34e1eaf0
Author: Simon McVittie <smcv at debian.org>
Date:   Wed Dec 30 12:55:57 2015 +0000

    GameData: do not crash if _iter_expand_groups changes self.files
---
 game_data_packager/__init__.py | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/game_data_packager/__init__.py b/game_data_packager/__init__.py
index d8ef300..5df3fd5 100644
--- a/game_data_packager/__init__.py
+++ b/game_data_packager/__init__.py
@@ -1094,6 +1094,10 @@ class GameData(object):
                     if f not in package.optional_files:
                         package.install_files.add(f)
 
+        # _iter_expand_groups could change the contents of self.files
+        for filename, f in list(self.files.items()):
+            f.provides_files = set(self._iter_expand_groups(f.provides))
+
         for filename, f in self.files.items():
             f.provides_files = set(self._iter_expand_groups(f.provides))
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/game-data-packager.git



More information about the Pkg-games-commits mailing list