From: acspike Date: Sun, 1 Apr 2007 21:47:10 +0000 (+0000) Subject: discard stderr from nested inkscape invocations X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=6f2291d178a59c46eedaeaca3a87013cca5f46be;p=inkscape.git discard stderr from nested inkscape invocations --- diff --git a/share/extensions/g2pngs.py b/share/extensions/g2pngs.py index a24906a04..675ea10a4 100644 --- a/share/extensions/g2pngs.py +++ b/share/extensions/g2pngs.py @@ -72,9 +72,10 @@ class MyEffect(inkex.Effect): name = "%s.png" % id filename = os.path.join(directory, name) command = "inkscape -i \"%s\" -e \"%s\" \"%s\" " % (id, filename, svg_file) - f = os.popen(command,'r') + _,f,err = os.popen3(command,'r') f.read() f.close() + err.close() pngs.append(filename) e = MyEffect() diff --git a/share/extensions/gimp_xcf.py b/share/extensions/gimp_xcf.py index 1da8a2609..998f5d9a1 100755 --- a/share/extensions/gimp_xcf.py +++ b/share/extensions/gimp_xcf.py @@ -41,9 +41,10 @@ class MyEffect(inkex.Effect): name = "%s.png" % id filename = os.path.join(tmp_dir, name) command = "inkscape -i %s -j %s -e %s %s " % (id, area, filename, svg_file) - f = os.popen(command,'r') + _,f,err = os.popen3(command,'r') f.read() f.close() + err.close() pngs.append(filename) names.append(id) diff --git a/share/extensions/summersnight.py b/share/extensions/summersnight.py index af660d9d9..803b2b372 100755 --- a/share/extensions/summersnight.py +++ b/share/extensions/summersnight.py @@ -47,9 +47,10 @@ class Project(inkex.Effect): file = self.args[-1] id = self.options.ids[0] for query in self.q.keys(): - f = os.popen("inkscape --query-%s --query-id=%s %s" % (query,id,file)) + _,f,err = os.popen3("inkscape --query-%s --query-id=%s %s" % (query,id,file)) self.q[query] = float(f.read()) f.close() + err.close() #process path d = obj.attributes.getNamedItem('d')