xip_file_write fix