// We manually start the adb-server so that later commands will not have to start it,
// allowing them to complete faster.
Proc adbStart = emu.getToolProcStarter(Tool.ADB, "start-server").stdout(logger).start();
adbStart.joinWithTimeout(5L, TimeUnit.SECONDS, listener);
Proc adbStart2 = emu.getToolProcStarter(Tool.ADB, "start-server").stdout(logger).start();
adbStart2.joinWithTimeout(5L, TimeUnit.SECONDS, listener);
// Determine whether we need to create the first snapshot
final SnapshotState snapshotState;
if (useSnapshots && androidSdk.supportsSnapshots()) {
boolean hasSnapshot = emuConfig.hasExistingSnapshot(launcher, androidSdk);