ms_driver: Do the existance check with the path

Change the existance test to use the full path and not just the
binary name.

Change-Id: Ibe28514df03efb7c302ac30411761a8d1a6dcf5d
This commit is contained in:
Holger Hans Peter Freyther 2018-12-03 14:10:05 +00:00
parent 51ae2b5f5c
commit 6bf882260a
1 changed files with 1 additions and 1 deletions

View File

@ -93,7 +93,7 @@ class MsDriver(log.Origin):
def check_and_return_binary(name):
"""Checks the binary exists and returns the path."""
binary = inst.child('bin', name)
if not os.path.isfile(name):
if not os.path.isfile(binary):
raise RuntimeError('Binary missing: %r' % binary)
return binary