mirror of
https://github.com/Genymobile/scrcpy.git
synced 2026-04-21 01:33:36 +00:00
`adb devices -l` prints one device per line, containing, separated by spaces: - the device serial, - the device state, - a list of key:value pairs. However, the device serial itself may contain spaces, making a simple split ambiguous. To avoid ambiguity, parse the string backwards: - first, parse all the trailing key-value pairs (containing ':'), - then, the preceding token (not containing ':') is the device state, - finally, the remaining leading token is the device serial. |
||
|---|---|---|
| .. | ||
| test_adb_parser.c | ||
| test_audiobuf.c | ||
| test_binary.c | ||
| test_cli.c | ||
| test_control_msg_serialize.c | ||
| test_device_msg_deserialize.c | ||
| test_orientation.c | ||
| test_str.c | ||
| test_strbuf.c | ||
| test_vecdeque.c | ||
| test_vector.c | ||