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

Commit 38f1b45d authored by Cao Peng's avatar Cao Peng Committed by Jia Jia
Browse files

Fix resource leakage caused by cursor



Change-Id: I9507658cc82a2b9760507530920a37044f7de2fd
Signed-off-by: default avatarJia Jia <jia.jia@zte.com.cn>
parent b2b16851
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -94,6 +94,8 @@ public class UserDictionaryCursorLoader extends CursorLoader {
            hashSet.add(hash);
            result.addRow(new Object[]{id, word, shortcut});
        }
        // The cursor needs to be closed after use, otherwise it will cause resource leakage
        candidate.close();
        return result;
    }
}