Removing memory management code - it is not needed, and finishing pack/unpack