You should avoid using xdr_short and especially xdr_char since they write their argument as ints and therefore waste disk space or network resources. The REFINE2/3D structures are for example packed into two resp. three ints on writing and unpacked on reading.
Copyright © by the Sonderforschungsbereich 256 at the Institut für Angewandte Mathematik, Universität Bonn.