Fix CameraRoll.getPhotos() crash on Android if device has a problematic video asset (#21438)

Summary:
Changed catching IOException to Exception
Fixes #20112
Pull Request resolved: https://github.com/facebook/react-native/pull/21438

Differential Revision: D10132453

Pulled By: hramos

fbshipit-source-id: c68fa8c45d43e4f2d116b8084ffd731ad6bf5aec
This commit is contained in:
Alexander Khaylo 2018-10-01 14:24:59 -07:00 committed by Facebook Github Bot
parent 5785445ae8
commit f1616a4e57

View File

@ -443,7 +443,7 @@ public class CameraRollManager extends ReactContextBaseJavaModule {
retriever.release();
photoDescriptor.close();
}
} catch (IOException e) {
} catch (Exception e) {
FLog.e(ReactConstants.TAG, "Could not get video metadata for " + photoUri.toString(), e);
return false;
}