csl-versions: fix syntax of gdb ver when there's an error

Signed-off-by: Christopher Larson <kergoth@gmail.com>
This commit is contained in:
Christopher Larson
2013-10-17 08:56:09 -07:00
parent 6be35fcbd6
commit 29a5e89e5f

View File

@@ -75,8 +75,8 @@ def csl_get_kernel_version(d):
def csl_get_gdb_version(d):
try:
stdout, stderr = csl_run(d, 'gdb', '-v')
except bb.process.CmdError as c:
return 'UNKNOWN(%s)' % c
except bb.process.CmdError:
return 'UNKNOWN'
else:
first_line = stdout.splitlines()[0]
return first_line.split()[-1]