mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-15 01:07:42 +00:00
2306 File Types Tree will no longer blow up and disappear with non standard mimeTypes
This commit is contained in:
parent
50be46cdee
commit
d98d80f031
@ -147,7 +147,9 @@ public final class FileTypesByMimeType extends Observable implements AutopsyVisi
|
||||
final String mime_type = resultSet.getString("mime_type"); //NON-NLS
|
||||
if (!mime_type.isEmpty()) {
|
||||
String mimeType[] = mime_type.split("/");
|
||||
if (!mimeType[0].isEmpty() && !mimeType[1].isEmpty()) {
|
||||
//Note: Users are able to define custom mime types in Autopsy that do not
|
||||
//contain a "/" or possibly have multiple slashes
|
||||
if (mimeType.length > 1 && !mimeType[0].isEmpty() && !mimeType[1].isEmpty()) {
|
||||
if (!existingMimeTypes.containsKey(mimeType[0])) {
|
||||
existingMimeTypes.put(mimeType[0], new ArrayList<>());
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user