Prevent crash

This commit is contained in:
M66B
2020-06-08 17:32:32 +02:00
parent cbb90435b4
commit bf672a4116
3 changed files with 8 additions and 0 deletions

View File

@@ -310,6 +310,8 @@ public class ActivityEML extends ActivityBase {
InputStream is;
try {
pfd = getContentResolver().openFileDescriptor(uri, "w");
if (pfd == null)
throw new FileNotFoundException(uri.toString());
os = new FileOutputStream(pfd.getFileDescriptor());
is = apart.part.getInputStream();