Minor adjustments to Android port
* java/org/gnu/emacs/EmacsService.java (readDirectoryEntry): Also refrain from returning NULL or file names containing non-representable NULL bytes. * src/callproc.c (get_current_directory): Clean up by employing android_is_special_directory.
This commit is contained in:
@@ -1503,9 +1503,13 @@ public final class EmacsService extends Service
|
||||
return entry;
|
||||
}
|
||||
|
||||
/* Skip this entry if its name cannot be represented. */
|
||||
/* Skip this entry if its name cannot be represented. NAME
|
||||
can still be null here, since some Cursors are permitted to
|
||||
return NULL if INDEX is not a string. */
|
||||
|
||||
if (name.equals ("..") || name.equals (".") || name.contains ("/"))
|
||||
if (name == null || name.equals ("..")
|
||||
|| name.equals (".") || name.contains ("/")
|
||||
|| name.contains ("\0"))
|
||||
continue;
|
||||
|
||||
/* Now, look for its type. */
|
||||
|
||||
Reference in New Issue
Block a user