change sizes to uint, write sizes as 4 byte integer (not string)