Fixed style according to reviewer and a refactoring error
I had to create this CL due to comitting before the final comments in the last CL
http://review.webrtc.org/1157005/ in revision:
https://code.google.com/p/webrtc/source/detail?r=3642
Changed e.msg to e.fail_msg in logging.error in emulate.py
Added space to error message for windows in check_permissions() in network_emulator
BUG=none
TEST=Windows and linux
Review URL: https://webrtc-codereview.appspot.com/1167006
git-svn-id: http://webrtc.googlecode.com/svn/trunk@3646 4adac7df-926f-26a2-2b94-8c16560cd09d
diff --git a/tools/network_emulator/emulate.py b/tools/network_emulator/emulate.py
index beaaf60..1c2cf3a 100755
--- a/tools/network_emulator/emulate.py
+++ b/tools/network_emulator/emulate.py
@@ -154,7 +154,7 @@
try:
emulator.check_permissions()
except network_emulator.NetworkEmulatorError as e:
- logging.error('Error: %s\n\nCause: %s', e.msg, e.error)
+ logging.error('Error: %s\n\nCause: %s', e.fail_msg, e.error)
return -1
if not options.target_ip:
@@ -186,7 +186,7 @@
logging.info('Completed Network Emulation.')
return 0
except network_emulator.NetworkEmulatorError as e:
- logging.error('Error: %s\n\nCause: %s', e.msg, e.error)
+ logging.error('Error: %s\n\nCause: %s', e.fail_msg, e.error)
return -2
if __name__ == '__main__':