fixed compiler warning
fixed size bug