diff options
| author | Michael Albinus | 2024-02-28 16:31:25 +0100 |
|---|---|---|
| committer | Michael Albinus | 2024-02-28 16:31:25 +0100 |
| commit | e490d2f8724c5e47d83c40c388f60e84f541dae5 (patch) | |
| tree | a38070e992ec06c0dde7a8cb16754213eec08130 | |
| parent | 1ddd9c8e29f721fcf6fcb17ef7a07fac0421c4f7 (diff) | |
| download | emacs-e490d2f8724c5e47d83c40c388f60e84f541dae5.tar.gz emacs-e490d2f8724c5e47d83c40c388f60e84f541dae5.zip | |
Revert change in tramp-adb-send-command
* lisp/net/tramp-adb.el (tramp-adb-send-command): Revert check for
`tramp-androidsu-method'. There is no need to restrict the check.
| -rw-r--r-- | lisp/net/tramp-adb.el | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/lisp/net/tramp-adb.el b/lisp/net/tramp-adb.el index 3f216ba403a..8ad7c271b4f 100644 --- a/lisp/net/tramp-adb.el +++ b/lisp/net/tramp-adb.el | |||
| @@ -1114,9 +1114,7 @@ error and non-nil on success." | |||
| 1114 | 1114 | ||
| 1115 | (defun tramp-adb-send-command (vec command &optional neveropen nooutput) | 1115 | (defun tramp-adb-send-command (vec command &optional neveropen nooutput) |
| 1116 | "Send the COMMAND to connection VEC." | 1116 | "Send the COMMAND to connection VEC." |
| 1117 | (if (and (equal (tramp-file-name-method vec) | 1117 | (if (string-match-p (rx multibyte) command) |
| 1118 | tramp-androidsu-method) | ||
| 1119 | (string-match-p (rx multibyte) command)) | ||
| 1120 | ;; Multibyte codepoints with four bytes are not supported at | 1118 | ;; Multibyte codepoints with four bytes are not supported at |
| 1121 | ;; least by toybox. | 1119 | ;; least by toybox. |
| 1122 | 1120 | ||
| @@ -1148,8 +1146,8 @@ error and non-nil on success." | |||
| 1148 | (while (search-forward-regexp (rx (+ "\r") eol) nil t) | 1146 | (while (search-forward-regexp (rx (+ "\r") eol) nil t) |
| 1149 | (replace-match "" nil nil))))))) | 1147 | (replace-match "" nil nil))))))) |
| 1150 | 1148 | ||
| 1151 | (defun tramp-adb-send-command-and-check (vec command &optional exit-status | 1149 | (defun tramp-adb-send-command-and-check |
| 1152 | command-augmented-p) | 1150 | (vec command &optional exit-status command-augmented-p) |
| 1153 | "Run COMMAND and check its exit status. | 1151 | "Run COMMAND and check its exit status. |
| 1154 | Sends `echo $?' along with the COMMAND for checking the exit | 1152 | Sends `echo $?' along with the COMMAND for checking the exit |
| 1155 | status. If COMMAND is nil, just sends `echo $?'. Returns nil if | 1153 | status. If COMMAND is nil, just sends `echo $?'. Returns nil if |
| @@ -1162,7 +1160,8 @@ Optional argument EXIT-STATUS, if non-nil, triggers the return of | |||
| 1162 | the exit status." | 1160 | the exit status." |
| 1163 | (tramp-adb-send-command | 1161 | (tramp-adb-send-command |
| 1164 | vec (if command | 1162 | vec (if command |
| 1165 | (if command-augmented-p command | 1163 | (if command-augmented-p |
| 1164 | command | ||
| 1166 | (format "%s; echo tramp_exit_status $?" command)) | 1165 | (format "%s; echo tramp_exit_status $?" command)) |
| 1167 | "echo tramp_exit_status $?")) | 1166 | "echo tramp_exit_status $?")) |
| 1168 | (with-current-buffer (tramp-get-connection-buffer vec) | 1167 | (with-current-buffer (tramp-get-connection-buffer vec) |