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

Commit 5d2f0da0 authored by Jay Shrauner's avatar Jay Shrauner Committed by Natiq Ahmed
Browse files

Fix NPE in markDropArea

Check for mDraggedEntry == null

Bug:18524967
Change-Id: I323cf41ddd21444d4fd675543b822c29517e8b26
parent a75dbeac
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -459,7 +459,8 @@ public class PhoneFavoritesTileAdapter extends BaseAdapter implements
     * @param itemIndex Position of the contact in {@link #mContactEntries}.
     */
    private void markDropArea(int itemIndex) {
        if (isIndexInBound(mDragEnteredEntryIndex) && isIndexInBound(itemIndex)) {
        if (mDraggedEntry != null && isIndexInBound(mDragEnteredEntryIndex) &&
                isIndexInBound(itemIndex)) {
            mDataSetChangedListener.cacheOffsetsForDatasetChange();
            // Remove the old placeholder item and place the new placeholder item.
            final int oldIndex = mDragEnteredEntryIndex;