The following commit has been merged in the master branch:
commit f5986b3e4139d8ebab1370be485987cd94b02112
Author: Mònica Ramírez Arceda <mon...@debian.org>
Date:   Tue Sep 3 21:21:18 2013 +0200

    Fix fix_build_xml.py when revision target does not exist

diff --git a/debian/changelog b/debian/changelog
index 7f8f55f..43e8703 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -5,6 +5,7 @@ josm-plugins (0.0.svn29866+ds1-1) UNRELEASED; urgency=low
   * debian/control:
     - Add myself to Uploaders.
     - Bump JOSM dependency to 6115.
+  * debian/fix_build_xml.py: Fix script when revision target does not exist.
 
  -- Mònica Ramírez Arceda <mon...@debian.org>  Tue, 03 Sep 2013 20:44:38 +0200
 
diff --git a/debian/fix_build_xml.py b/debian/fix_build_xml.py
index 52839ae..f41d9cc 100755
--- a/debian/fix_build_xml.py
+++ b/debian/fix_build_xml.py
@@ -18,9 +18,9 @@ def main():
     doc = minidom.parse(orig_filename)
 
     # Remove Internet access in revision target
-    [revision_target] = [target for target in 
doc.getElementsByTagName('target')
-                         if target.attributes['name'].value == 'revision']
-    revision_target.childNodes = []
+    for target in doc.getElementsByTagName('target'):
+        if target.attributes['name'].value == 'revision':
+            target.childNodes = []
     #revision_target.childNodes = [node for node in revision_target.childNodes
     #                              if node.nodeName != 'exec' and 
node.nodeName != 'delete']
     #[xmlproperty_node] = [node for node in revision_target.childNodes

-- 
Plugins for JOSM

_______________________________________________
Pkg-osm-commits mailing list
Pkg-osm-commits@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-osm-commits

Reply via email to