Index: chrome/test/data/native_messaging/native_hosts/echo.py |
diff --git a/chrome/test/data/native_messaging/native_hosts/echo.py b/chrome/test/data/native_messaging/native_hosts/echo.py |
index 28e02f735555f8af58de220e97df68ce4fc72018..a611051dd183c833cba5493e5dc30bdcbe41a60c 100755 |
--- a/chrome/test/data/native_messaging/native_hosts/echo.py |
+++ b/chrome/test/data/native_messaging/native_hosts/echo.py |
@@ -23,20 +23,19 @@ def WriteMessage(message): |
def Main(): |
message_number = 0 |
- caller_url = None |
parent_window = None |
if len(sys.argv) < 2: |
sys.stderr.write("URL of the calling application is not specified.\n") |
return 1 |
+ caller_url = sys.argv[1] |
+ |
# TODO(sergeyu): Use argparse module to parse the arguments (not available in |
# Python 2.6). |
- for arg in sys.argv[1:]: |
+ for arg in sys.argv[2:]: |
if arg.startswith('--'): |
if arg.startswith('--parent-window='): |
parent_window = long(arg[len('--parent-window='):]) |
- elif caller_url == None: |
- caller_url = arg |
# Verify that the process was started in the correct directory. |
cwd = os.getcwd() |