1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-05 03:20:39 -08:00

Fix crashes in Android port

* java/org/gnu/emacs/EmacsService.java (queryTree): Fix NULL
pointer dereference.
* src/android.c (android_query_tree): Set *nchildren_return.
This commit is contained in:
Po Lu 2023-01-13 16:08:11 +08:00
parent 7e35af1a10
commit 24910d3f37
2 changed files with 4 additions and 1 deletions

View file

@ -304,7 +304,9 @@ public class EmacsService extends Service
array = new short[windowList.size () + 1];
i = 1;
array[0] = window.parent != null ? 0 : window.parent.handle;
array[0] = (window == null
? 0 : (window.parent != null
? window.parent.handle : 0));
for (EmacsWindow treeWindow : windowList)
array[i++] = treeWindow.handle;