libs/gui: Release acquired buffer when createImage fails …