Passing parameters by value or by reference in C and C++ routines
For C and C++ routines, parameter values must always be passed by reference to routines using pointers.
This is required for input-only, input-output, and output parameters by reference.
Null-indicator parameters must also be passed by reference to routines using pointers.
The database manager control the allocation of memory for all parameters and maintain C or C++ references to all parameters that are passed into or out of a routine. There is no need to allocate or free memory that is associated with routine parameters and null indicators.