Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 29994200 authored by Marco Nelissen's avatar Marco Nelissen
Browse files

Fix media scan NPE

b/7966288

Change-Id: I066bc9f00bccf070332d87d6f1bf3d6054b31136
parent 0ada5d65
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -958,7 +958,9 @@ public class MediaScanner
                // If the rowId of the inserted file is needed, it gets inserted immediately,
                // bypassing the bulk inserter.
                if (inserter == null || needToSetSettings) {
                    if (inserter != null) {
                        inserter.flushAll();
                    }
                    result = mMediaProvider.insert(tableUri, values);
                } else if (entry.mFormat == MtpConstants.FORMAT_ASSOCIATION) {
                    inserter.insertwithPriority(tableUri, values);