fix bug of struct size differs