camera2: prevent NPE because a null inage data has been added

Happens mostly with video snapshots

E/AndroidRuntime(18624): java.lang.NullPointerException

E/AndroidRuntime(18624): at com.android.camera.data.LocalData.compare(LocalData.java:186)
E/AndroidRuntime(18624): at com.android.camera.data.LocalData.compare(LocalData.java:170)
E/AndroidRuntime(18624): at com.android.camera.data.CameraDataAdapter.insertData(CameraDataAdapter.java:247)
E/AndroidRuntime(18624): at com.android.camera.data.CameraDataAdapter.addNewPhoto(CameraDataAdapter.java:171)
E/AndroidRuntime(18624): at com.android.camera.data.AbstractLocalDataAdapterWrapper.addNewPhoto(AbstractLocalDataAdapterWrapper.java:74)
E/AndroidRuntime(18624): at com.android.camera.CameraActivity.notifyNewMedia(CameraActivity.java:760)
E/AndroidRuntime(18624): at com.android.camera.VideoModule.onMediaSaved(VideoModule.java:193)
E/AndroidRuntime(18624): at com.android.camera.MediaSaveService.onPostExecute(MediaSaveService.java:188)
E/AndroidRuntime(18624): at com.android.camera.MediaSaveService.onPostExecute(MediaSaveService.java:141)
E/AndroidRuntime(18624): at android.os.AsyncTask.finish(AsyncTask.java:632)
E/AndroidRuntime(18624): at android.os.AsyncTask.access00(AsyncTask.java:177)
E/AndroidRuntime(18624): at android.os.AsyncTask.handleMessage(AsyncTask.java:645)
E/AndroidRuntime(18624): at android.os.Handler.dispatchMessage(Handler.java:102)
E/AndroidRuntime(18624): at android.os.Looper.loop(Looper.java:137)
E/AndroidRuntime(18624): at android.app.ActivityThread.main(ActivityThread.java:4998)
E/AndroidRuntime(18624): at java.lang.reflect.Method.invokeNative(Native Method)
E/AndroidRuntime(18624): at java.lang.reflect.Method.invoke(Method.java:515)
E/AndroidRuntime(18624): at com.android.internal.os.ZygoteInit.run(ZygoteInit.java:777)
E/AndroidRuntime(18624): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:593)
E/AndroidRuntime(18624): at dalvik.system.NativeStart.main(Native Method)

Change-Id: I97277371414e8c850370d779f25779662cb44e49
Merge "camera2: prevent NPE because a null inage data has been added" into android-4.4