Compare commits

...

1 Commits

Author SHA1 Message Date
x7z4w
89bcc9894d [android] Do not crash on unknown types
Signed-off-by: x7z4w <x7z4w@noreply.codeberg.org>
2025-10-19 12:27:20 +02:00

View File

@@ -88,7 +88,7 @@ public class Metadata implements Parcelable
if (type.mMetaType == metaType)
return type;
throw new IllegalArgumentException("Illegal metaType: " + metaType);
return -1;
}
public int toInt()
@@ -102,6 +102,9 @@ public class Metadata implements Parcelable
public void addMetadata(int metaType, String metaValue)
{
final MetadataType type = MetadataType.fromInt(metaType);
if (type == -1)
return;
mMetadataMap.put(type, metaValue);
}