Commit 65a0687a authored by newt@chromium.org's avatar newt@chromium.org

Add adb version check to adb_remote_setup.sh.

This ensures that the local and remote versions of adb are the same,
since using different versions of adb will probably result in protocol
errors.

NOTRY=true

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@284181 0039d316-1c4b-4281-b951-d872f2087c98
parent 94bd40d9
...@@ -61,6 +61,19 @@ if which kinit >/dev/null; then ...@@ -61,6 +61,19 @@ if which kinit >/dev/null; then
kinit -R || kinit kinit -R || kinit
fi fi
# Ensure local and remote versions of adb are the same.
remote_adb_version=$(ssh "$remote_host" "$remote_adb version")
local_adb_version=$(adb version)
if [[ "$local_adb_version" != "$remote_adb_version" ]]; then
echo >&2
echo "WARNING: local adb is not the same version as remote adb." >&2
echo "This should be fixed since it may result in protocol errors." >&2
echo " local adb: $local_adb_version" >&2
echo " remote adb: $remote_adb_version" >&2
echo >&2
sleep 5
fi
# Kill the adb server on the remote host. # Kill the adb server on the remote host.
ssh "$remote_host" "$remote_adb kill-server" ssh "$remote_host" "$remote_adb kill-server"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment