Skip to content

Commit

Permalink
fix: track_devices support multiple devices (#83)
Browse files Browse the repository at this point in the history
  • Loading branch information
KFBI1706 authored Jan 21, 2025
1 parent 331ef95 commit 144072b
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion adb_client/src/server/commands/devices.rs
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,12 @@ impl ADBServer {
.get_raw_connection()?
.read_exact(&mut body)?;

callback(DeviceShort::try_from(body)?)?;
for device in body.split(|x| x.eq(&b'\n')) {
if device.is_empty() {
break;
}
callback(DeviceShort::try_from(device.to_vec())?)?;
}
}
}
}
Expand Down

0 comments on commit 144072b

Please sign in to comment.