Continue running if the upstream remote exists.

We already have code to check the git remotes to see if the upstream
exists, but apparently it does not always succeed (see
http://108.170.220.27:10115/builders/Housekeeper-PerCommit-AndroidRoll/builds/684/steps/Merge/logs/stdio
and
http://108.170.220.27:10115/builders/Housekeeper-PerCommit-AndroidRoll/builds/662/steps/Merge/logs/stdio
).

R=borenet@google.com

Author: scroggo@google.com

Review URL: https://codereview.chromium.org/317823006
diff --git a/slave/skia_slave_scripts/merge_into_android.py b/slave/skia_slave_scripts/merge_into_android.py
index f072d86..27ebcd1 100644
--- a/slave/skia_slave_scripts/merge_into_android.py
+++ b/slave/skia_slave_scripts/merge_into_android.py
@@ -56,8 +56,18 @@
     with misc.ChDir(EXTERNAL_SKIA):
       # Check to see whether there is an upstream yet.
       if not UPSTREAM_REMOTE_NAME in shell_utils.run([GIT, 'remote', 'show']):
-        shell_utils.run([GIT, 'remote', 'add', UPSTREAM_REMOTE_NAME,
-                         SKIA_REPO_URL])
+        try:
+          shell_utils.run([GIT, 'remote', 'add', UPSTREAM_REMOTE_NAME,
+                           SKIA_REPO_URL])
+        except shell_utils.CommandFailedException as e:
+          if 'remote %s already exists' % UPSTREAM_REMOTE_NAME in e.output:
+            # Accept this error. The upstream remote name should have been in
+            # the output of git remote show, which would have made us skip this
+            # redundant command anyway.
+            print ('%s was already added. Why did it not show in git remote'
+                   ' show?' % UPSTREAM_REMOTE_NAME)
+          else:
+            raise e
 
       # Update the upstream remote.
       shell_utils.run([GIT, 'fetch', UPSTREAM_REMOTE_NAME])