Bug fixed when out and err are None in operation exec_command

remotes/github/oglive^2
Juan Manuel Bardallo 2019-05-27 10:48:30 +02:00 committed by Ramón M. Gómez
parent 53f167e585
commit fb1405778b
1 changed files with 1 additions and 2 deletions

View File

@ -223,8 +223,7 @@ def exec_command(cmd):
logger.debug("ERROR EXEC COMMAND: {}".format(str(e)))
stat = proc.returncode
return stat, out.decode(chardet.detect(out)['encoding']).encode('utf8'),\
err.decode(chardet.detect(err)['encoding']).encode('utf8')
return stat, out, err
def get_hardware():