| Index: build/android/devil/android/ports.py
|
| diff --git a/build/android/devil/android/ports.py b/build/android/devil/android/ports.py
|
| index 49ee4e34e376c3471632ceb35bf6ce013feedaf2..eff30ced0f53ec0845070fb37aef02e5d9993146 100644
|
| --- a/build/android/devil/android/ports.py
|
| +++ b/build/android/devil/android/ports.py
|
| @@ -37,8 +37,8 @@ def ResetTestServerPortAllocation():
|
| if os.path.exists(_TEST_SERVER_PORT_LOCKFILE):
|
| os.unlink(_TEST_SERVER_PORT_LOCKFILE)
|
| return True
|
| - except Exception as e:
|
| - logging.error(e)
|
| + except Exception: # pylint: disable=broad-except
|
| + logging.exception('Error while resetting port allocation')
|
| return False
|
|
|
|
|
| @@ -69,8 +69,8 @@ def AllocateTestServerPort():
|
| else:
|
| fp.seek(0, os.SEEK_SET)
|
| fp.write('%d' % (port + 1))
|
| - except Exception as e:
|
| - logging.error(e)
|
| + except Exception: # pylint: disable=broad-except
|
| + logging.exception('ERror while allocating port')
|
| finally:
|
| if fp_lock:
|
| fcntl.flock(fp_lock, fcntl.LOCK_UN)
|
|
|