incount in MPI_Pack_size() is not unsigned int as stated in the reference example, but a signed integer