xref: /aosp_15_r20/external/cronet/build/android/pylib/restart_adbd.sh (revision 6777b5387eb2ff775bb5750e3f5d96f37fb7352b)
1#!/system/bin/sh
2
3# Copyright 2014 The Chromium Authors
4# Use of this source code is governed by a BSD-style license that can be
5# found in the LICENSE file.
6
7# Android shell script to restart adbd on the device. This has to be run
8# atomically as a shell script because stopping adbd prevents further commands
9# from running (even if called in the same adb shell).
10
11trap '' HUP
12trap '' TERM
13trap '' PIPE
14
15function restart() {
16  stop adbd
17  start adbd
18}
19
20restart &
21