Do Not Pass Local Values
If you exchange structs or binary buffers, remember that many data types could be meaningless at the receiving end. For example, a pointer is a memory address inside a particular computer—it has no meaning to any other program running on other computers. You must always send actual data by value rather than referencing it with a pointer.
Many opaque data structures or quantities are similarly meaningless outside of a particular program (for example, UNIX file descriptors). Do not send this kind of data to other programs.