Fixed new packing/unpacking function for Nodist and ZMQ layers