Check for null URIs

This commit is contained in:
M66B
2021-08-07 08:11:34 +02:00
parent 1f449c9e58
commit 8f46bdebd1
6 changed files with 43 additions and 8 deletions

View File

@@ -6542,6 +6542,9 @@ public class FragmentMessages extends FragmentBase implements SharedPreferences.
long id = args.getLong("id");
Uri uri = args.getParcelable("uri");
if (uri == null)
throw new FileNotFoundException();
if (!"content".equals(uri.getScheme())) {
Log.w("Save raw uri=" + uri);
throw new IllegalArgumentException(context.getString(R.string.title_no_stream));