Fix a Cursor leak

When cursor is done, the cursor must be closed to avoid cursor leak.

This was merged in AOSP: https://android-review.googlesource.com/#/c/54993/

Change-Id: I8d837dd50473c3b14806f54ca8a78de14178b0cb