Home
Developer Resources
QNX RTOS v4
QNX RTOS v4 Knowledge Base

QNX RTOS v4 Knowledge Base

Foundry27
Foundry27
QNX RTOS v4 project
Resources

QNX RTOS v4 Knowledge Base

Title RPC Problem with XDR
Ref. No. QNX.000001555
Category(ies) Network, Development
Issue A memory violation ocurrs for either xdr_getpos() or xdr_destroy(). Debugging this shows that in both cases the problem is the xdr_ops substructure which has some strange values. It seems that the xdrmem_create() did not correctly initialized the XDR structure.

This is using QNX 4.25, TCP/IP 4.25, and Watcom 10.6 with the latest updates.







Solution All RPC programs need to be compiled using "-Wc,-ei". This means the compiler will allocate the smallest possible storage for an enumerated list, and can be used to force an integer to be allocated for all enumerated types.

This requirement is documented in 4.25.