Fixed an imageRef leak in image+ykutils

Fixed an imageRef leak in image+ykutils