Fix of gramps -v for Graphviz and ghostscript.
svn: r21301
This commit is contained in:
parent
2cb390881b
commit
1db1aefc81
@ -282,8 +282,10 @@ def show_settings():
|
|||||||
|
|
||||||
try:
|
try:
|
||||||
dotversion_str = Popen(['dot', '-V'], stderr=PIPE).communicate(input=None)[1]
|
dotversion_str = Popen(['dot', '-V'], stderr=PIPE).communicate(input=None)[1]
|
||||||
|
if isinstance(dotversion_str, bytes):
|
||||||
|
dotversion_str = dotversion_str.decode(sys.stdin.encoding)
|
||||||
if dotversion_str:
|
if dotversion_str:
|
||||||
dotversion_str = dotversion_str.replace('\n','')
|
dotversion_str = dotversion_str.replace('\n','')[23:27]
|
||||||
except:
|
except:
|
||||||
dotversion_str = 'Graphviz not in system PATH'
|
dotversion_str = 'Graphviz not in system PATH'
|
||||||
|
|
||||||
@ -292,6 +294,8 @@ def show_settings():
|
|||||||
gsversion_str = Popen(['gswin32c', '--version'], stdout=PIPE).communicate(input=None)[0]
|
gsversion_str = Popen(['gswin32c', '--version'], stdout=PIPE).communicate(input=None)[0]
|
||||||
else:
|
else:
|
||||||
gsversion_str = Popen(['gs', '--version'], stdout=PIPE).communicate(input=None)[0]
|
gsversion_str = Popen(['gs', '--version'], stdout=PIPE).communicate(input=None)[0]
|
||||||
|
if isinstance(gsversion_str, bytes):
|
||||||
|
gsversion_str = gsversion_str.decode(sys.stdin.encoding)
|
||||||
if gsversion_str:
|
if gsversion_str:
|
||||||
gsversion_str = gsversion_str.replace('\n', '')
|
gsversion_str = gsversion_str.replace('\n', '')
|
||||||
except:
|
except:
|
||||||
|
Loading…
Reference in New Issue
Block a user