Make port unmapping errors non fatal.

In some cases port unmapping can fail. This should not be fatal nor need client
recovery code.

This can happen when multiple instances of the Forwarder class try to map/unmap
a same port. While the host_forwarder daemon supports that, the python wrapper
didn't.

R=bulach@chromium.org

Review URL: https://codereview.chromium.org/18714004

git-svn-id: http://src.chromium.org/svn/trunk/src/build@210306 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
This commit is contained in:
pliard@chromium.org 2013-07-05 14:33:32 +00:00
Родитель c664eec31b
Коммит 982dbd5ac1
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -128,7 +128,7 @@ class Forwarder(object):
(exit_code, output) = cmd_helper.GetCmdStatusAndOutput(
[self._host_forwarder_path] + redirection_command)
if exit_code != 0:
raise Exception('%s exited with %d:\n%s' % (
logging.error('%s exited with %d:\n%s' % (
self._host_forwarder_path, exit_code, '\n'.join(output)))
host_port = self._device_to_host_port_map[device_port]
del self._device_to_host_port_map[device_port]