Fix NPE in DownloadProvider.

Bug: 122434250
Test: manual
Exempt-From-Owner-Approval: minor fix to resolve a chase list bug
Change-Id: I7a4a64ae0fa42eb0571d78a34166ac96457ce43a
(cherry picked from commit c93b9b181562bac87ba3082b0a11da3b1e7ac02d)
diff --git a/src/com/android/providers/downloads/DownloadProvider.java b/src/com/android/providers/downloads/DownloadProvider.java
index 2523f88..8dc1450 100644
--- a/src/com/android/providers/downloads/DownloadProvider.java
+++ b/src/com/android/providers/downloads/DownloadProvider.java
@@ -1361,8 +1361,8 @@
                                         .DESTINATION_NON_DOWNLOADMANAGER_DOWNLOAD) {
                             final Uri mediaStoreUri = updateMediaProvider(client,
                                     info.mMediaStoreUri, convertToMediaProviderValues(info));
-                            if (!TextUtils.equals(
-                                    info.mMediaStoreUri, mediaStoreUri.toString())) {
+                            if (!TextUtils.equals(info.mMediaStoreUri,
+                                    mediaStoreUri == null ? null : mediaStoreUri.toString())) {
                                 final ContentValues updateValues = new ContentValues();
                                 if (mediaStoreUri == null) {
                                     updateValues.putNull(Downloads.Impl.COLUMN_MEDIASTORE_URI);