[Util] Fixed a dead write in XWrapper.