From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Po Lu via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#64445: 30.0.50; Android: Emacs cannot access /storage/emulated/0 although other apps can Date: Wed, 05 Jul 2023 20:21:29 +0800 Message-ID: <878rbuo8fq.fsf@yahoo.com> References: <87zg4c92l4.fsf@zamazal.org> <87a5wcsdpg.fsf@yahoo.com> <871qhohziz.fsf@zamazal.org> <87lefwqdsy.fsf@yahoo.com> <87ttukgiwh.fsf@zamazal.org> <871qhnp4sd.fsf@yahoo.com> <87pm56g5zl.fsf@zamazal.org> <87lefuokkt.fsf@yahoo.com> <87h6qig0ag.fsf@zamazal.org> Reply-To: Po Lu Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="1378"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: 64445@debbugs.gnu.org To: Milan Zamazal Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Jul 05 14:22:24 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1qH1Wa-000Adh-3u for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 05 Jul 2023 14:22:24 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qH1WG-00055a-8M; Wed, 05 Jul 2023 08:22:04 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qH1WE-00054u-FV for bug-gnu-emacs@gnu.org; Wed, 05 Jul 2023 08:22:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qH1WE-0007eM-7C for bug-gnu-emacs@gnu.org; Wed, 05 Jul 2023 08:22:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qH1WE-0004cE-2q for bug-gnu-emacs@gnu.org; Wed, 05 Jul 2023 08:22:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Po Lu Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 05 Jul 2023 12:22:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 64445 X-GNU-PR-Package: emacs Original-Received: via spool by 64445-submit@debbugs.gnu.org id=B64445.168855971417719 (code B ref 64445); Wed, 05 Jul 2023 12:22:02 +0000 Original-Received: (at 64445) by debbugs.gnu.org; 5 Jul 2023 12:21:54 +0000 Original-Received: from localhost ([127.0.0.1]:37875 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qH1W2-0004bY-4X for submit@debbugs.gnu.org; Wed, 05 Jul 2023 08:21:54 -0400 Original-Received: from sonic303-21.consmr.mail.ne1.yahoo.com ([66.163.188.147]:45606) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qH1Vz-0004b3-RG for 64445@debbugs.gnu.org; Wed, 05 Jul 2023 08:21:48 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1688559700; bh=FjkLWNHsu7eMrUX8WwGymxaZg99sdjZiO6zS2kwYuGA=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From:Subject:Reply-To; b=AW/A9lwoUjRIisX76xRp51SkGyEUiZZKuSR41kE4UC0k9DtiY1Zgw9TfQzWKxSCzQhBjL6UTYcoOftAtulWMTM1JJCrk13fxEuLRLU21VUwyTx7AZ0BueukU7IVODA5loxhpmnyQFz8CM5MiNB5Yj7MchMbTTZlzywdWPr8YY0sdMjCk0nLf/NcV3xB9g9QxGXC6ZAwyWYKc3+eRxGh5YMfhleWznr2jdogQ6z+qa8J3PucFK3JqoMPpCjneyeqlqqGu+I2KCnrNYsCD/NMvrf8Soq5+7ncUnW29im1jw35zlRcRpS6wzVJWIV0YQKWUYxySOttr+sCVJDNntbToDA== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1688559700; bh=MYs2t9A2ORFlyHQLyGyjvVxgT4goqVrzzZRY95NCoYq=; h=X-Sonic-MF:From:To:Subject:Date:From:Subject; b=r7iw9OFgDORGUMhkPRksHU35pbdbcPNDAk+/1qAPGsY9LiVISRNwU8G3YYnlos7mTE0Sp6hRyHzQJIge3klbFjMDTIblwKj6BS+jzWwWu568J1hAfS/G0MbgIVY05we2zhlvufZl9glSttt2Wt2gDCTuFqI3HW0546h9eNGou+4WcZrO7TTUMvlPmQXT7rD/far6M9UifvP+T3w/t7D4B2ZsnOInXSkYixAdfq+rOPTvGuL87TjzvYE62LzCxiils3XgVu0gVeTRn0sntfjv0sawEZiQEJDuxIBV7SwCJzwELo+Gv88DqdBgIHQxL7XC8ZAKJkloMnYi+6RwxtmgyA== X-YMail-OSG: zYco0DwVM1mKKwXAQFm2RwywhHgTzAXVZCv3LehbWtXibz9iP7kQwt3WD18FeWb 4dsiBp77w8O_Nn10.905N2quZr2IDRO8aBMZ7pZWMDiMP..ujawnOS.TQ46QPB30CV5xResrxpjV X_bdx4rcQnEVghP0yvo6hFj2qPcokVrHHmFkfIJTwO1qghdNJIP8YNo7JBSgSRR3HXAOwSQ4LuxU iJtC3N01B_VxonXNLdw.dKsLiIZENVweP8QKQOrfhgjrj0TFEx11U2RTn.IvwGEzpcDKXJQvWzQb pvYvzI.yCcz6Kp3SO0ftGQiZrlMMLVVV6NxHl3E28tnSBXbUWn9E2.NLS7CXxOiuPdto31N.Q0q3 T_J16w8Em_ONSDuRSkqpnIPuXWWARQicwFQlOo1t2oljvtnmVsfi1NvSLbLDSMhpFnKj9ynOwf6X snwd3TYsGAOHlFbHETOcNEG0IeX1PqpQz7NbwfZlB_FmthbdBpyxKYnllHU0nyfZtYsW5AgdXiCu XmOH_gcx66MLkz0KoDdOTJzgzBDlEpqLRBZkb8q1ZebObW0dViDE76fJxVglXj1kYPzKFOSpBbkq Rk4yhaj7dAPBjKtdaNrR2zA5WdQ50TvlvdfzlvjR_Ma231WGE4YtI4GTzYPP4XJ63y14DRfG031h sl22JkvuOtgyj_Abvqzn67xnyrM.0R6c8BnDzY2IGUv_19L_OlKJGodXWHxQq.tKG0GYB4OQNAAd 6FxkSy0hFrOwnTWZmQMz1B6AaPNYzzWSPPpCdzkdv34sbdCb.mxrBwxEhL3Z2pzrOVJHmUp2ORLo rKfCnAtW7kdnABh5iksbV39xGMCzb7tQLs5df9hYkx X-Sonic-MF: X-Sonic-ID: 248e4a5a-8059-4eea-aba6-c1ccecad52fe Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic303.consmr.mail.ne1.yahoo.com with HTTP; Wed, 5 Jul 2023 12:21:40 +0000 Original-Received: by hermes--production-sg3-67fd64777-8smhp (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID 04eb3b3c90890bc9ac904fecd9b88ee3; Wed, 05 Jul 2023 12:21:34 +0000 (UTC) In-Reply-To: <87h6qig0ag.fsf@zamazal.org> (Milan Zamazal's message of "Wed, 05 Jul 2023 11:44:39 +0200") X-Mailer: WebService/1.1.21612 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:264628 Archived-At: Milan Zamazal writes: >>>>>> "PL" =3D=3D Po Lu writes: > > PL> Milan Zamazal writes: > >> W org.gnu.emacs: type=3D1400 audit(0.0:910): avc: denied { read } > >> for comm=3D456D616373206D61696E2074687265 name=3D"/" dev=3D"dm-0" = ino=3D2 > >> scontext=3Du:r:untrusted_app:s0:c157,c256,c512,c768 > >> tcontext=3Du:object_r:rootfs:s0 tclass=3Ddir permissive=3D0 > > PL> Right... how exactly are you trying to access /sdcard? Through > PL> Dired? > > Yes, for example: =E2=80=98C-x C-f /sdcard/ RET=E2=80=99 > > PL> If so, my guess is that ls-lisp is trying to stat the root file > PL> system, which is forbidden by some versions of Android. Would > PL> you please enable debug-on-error (Options -> Enter Debugger on > PL> Error) and display the backtrace from whatever file access > PL> operation complains? > > It's this one: > > directory-files-and-attributes("/sdcard/" nil nil t string) > > I also tried what happens in =E2=80=98M-x shell=E2=80=98 and for example = =E2=80=98cat=E2=80=99 does the > same: > > $ cat /sdcard/existent-file > cat: /sdcard/existent-file: Permission denied > $ cat /sdcard/non-existent-file > cat: /sdcard/non-existent-file: No such file or directory > > This at least verifies that /sdcard points to the right location. > > The same happens in Termux if and only if I remove the given storage > permission from it. But in Emacs, it happens whether the permission is > given or not. I think this should now be fixed. Prebuilts will be available in approximately 20 minutes. Would you please test them and ack?