]> git.eshelyaron.com Git - emacs.git/commit
Correctly receive files through Android DND
authorPo Lu <luangruo@yahoo.com>
Sun, 15 Oct 2023 05:10:34 +0000 (13:10 +0800)
committerPo Lu <luangruo@yahoo.com>
Sun, 15 Oct 2023 05:11:37 +0000 (13:11 +0800)
commit93104cff532f932bcea65d02a59c916767a31645
tree20070ee4cb8500824fceef285bd4b104ada3748b
parenta3fd382f3fe803e0b61c5353e9b5bdaf4d1e564e
Correctly receive files through Android DND

* java/org/gnu/emacs/EmacsService.java (getUsefulContentResolver)
(getContentResolverContext): New functions which return a
content resolver from an EmacsActivity, if at all possible.
(openContentUri, checkContentUri): Probe or open URIs through
such content resolvers.  Probe URIs by opening them if merely
testing permissions fails, for DND URIs do not make
checkCallingUriPermission return true.

* java/org/gnu/emacs/EmacsWindow.java (onDragEvent): Address
potential crash.

* src/androidvfs.c (android_check_content_access): Circumvent
JNI dynamic method dispatch.
(android_authority_name): Guarantee NAME is never a directory.
java/org/gnu/emacs/EmacsService.java
java/org/gnu/emacs/EmacsWindow.java
src/androidvfs.c