[Pkg-bazaar-commits] ./bzr-builddeb/trunk.old r230: Correct old users of the import_tar API to use file_ids_from correctly.

James Westby jw+debian at jameswestby.net
Wed Dec 10 08:32:46 UTC 2008


------------------------------------------------------------
revno: 230
committer: James Westby <jw+debian at jameswestby.net>
branch nick: import
timestamp: Tue 2008-06-10 17:07:55 +0100
message:
  Correct old users of the import_tar API to use file_ids_from correctly.
modified:
  import_dsc.py
-------------- next part --------------
=== modified file 'import_dsc.py'
--- a/import_dsc.py	2008-06-10 13:13:04 +0000
+++ b/import_dsc.py	2008-06-10 16:07:55 +0000
@@ -297,7 +297,10 @@
                                  make_upstream_tag(last_upstream))
         tree.revert(None,
                     tree.branch.repository.revision_tree(old_upstream_revid))
-      import_tar(tree, f, file_ids_from=[dangling_tree])
+      file_ids_from = []
+      if dangling_tree is not None:
+        file_ids_from = [dangling_tree]
+      import_tar(tree, f, file_ids_from=file_ids_from)
       if last_upstream is not None:
         tree.set_parent_ids([old_upstream_revid])
         revno = tree.branch.revision_id_to_revno(old_upstream_revid)
@@ -327,7 +330,10 @@
           dangling_tree = tree.branch.repository.revision_tree(dangling_revid)
         tree.revert(None,
                     tree.branch.repository.revision_tree(old_upstream_revid))
-      import_tar(tree, f, file_ids_from=[dangling_tree])
+      file_ids_from = []
+      if dangling_tree is not None:
+        file_ids_from = [dangling_tree]
+      import_tar(tree, f, file_ids_from=file_ids_from)
       if last_upstream is not None:
         tree.set_parent_ids([old_upstream_revid])
         revno = tree.branch.revision_id_to_revno(old_upstream_revid)



More information about the Pkg-bazaar-commits mailing list