Close cursor before finalizing

GPUImage.getImageOrientation() doesn't close a used cursor properly which results in a warning. This fixes it.