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

Commit 4802b410 authored by Sunny Goyal's avatar Sunny Goyal
Browse files

Adding null-check before parsing an intent

Bug: 18962665
Change-Id: Iae02435f019fa205f3ee3ae721a29f26b3b56dd2
parent b76c165a
Loading
Loading
Loading
Loading
+3 −1
Original line number Original line Diff line number Diff line
@@ -104,7 +104,9 @@ public class UninstallShortcutReceiver extends BroadcastReceiver {
            try {
            try {
                while (c.moveToNext()) {
                while (c.moveToNext()) {
                    try {
                    try {
                        if (intent.filterEquals(Intent.parseUri(c.getString(intentIndex), 0))) {
                        String intentStr = c.getString(intentIndex);
                        if (intentStr != null
                                && intent.filterEquals(Intent.parseUri(intentStr, 0))) {
                            final long id = c.getLong(idIndex);
                            final long id = c.getLong(idIndex);
                            final Uri uri = LauncherSettings.Favorites.getContentUri(id, false);
                            final Uri uri = LauncherSettings.Favorites.getContentUri(id, false);
                            cr.delete(uri, null, null);
                            cr.delete(uri, null, null);