mirror of
https://github.com/M66B/FairEmail.git
synced 2026-01-15 17:19:23 +01:00
Remove NUL characters from file names
This commit is contained in:
@@ -1012,7 +1012,10 @@ public class Helper {
|
||||
if (name == null)
|
||||
return null;
|
||||
|
||||
return name.replaceAll("[?:\"*|/\\\\<>]", "_");
|
||||
return name
|
||||
// Canonical files names cannot contain NUL
|
||||
.replace("\0", "")
|
||||
.replaceAll("[?:\"*|/\\\\<>]", "_");
|
||||
}
|
||||
|
||||
static String getExtension(String filename) {
|
||||
|
||||
Reference in New Issue
Block a user