+0
−1
+6
−6
adb/backup_service.c
deleted100644 → 0
+0
−152
+57
−15
+108
−44
Loading
Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more
To facilitate device scripts that want to read/write binary data from the host side, this change introduces a new "exec" service that behaves like "shell" but without creating a pty, which would otherwise mangle binary data. After forking, it hooks up stdin/stdout of the child process to the socket connected through to the host. The adb transport doesn't support shutdown(), so the host can't half-close the socket and wait for device termination. Instead, the host side now has two explicit commands "exec-in" and "exec-out" for either sending or receiving data. Teach host side copy_to_file() to deal with stdin/stdout special cases. Switch device side backup/restore services to use the new create_subproc_raw under the hood. (cherry picked from commit 5d9d434e) Change-Id: I42c18cb5bb907449b458c94450ef6c584d84ecdb