[xkb] fix some memory leak