|
We believe that we may have discovered the reason. For whatever the
reason, it is somewhat difficult to find a proper prototype
definition for CEEMOUT and the one that we have been using and, of
course, copying from program to program, looks like this:
// Call system api to write message to screen or job log
dcl-pr WriteMessage extproc('CEEMOUT') opdesc;
@i_msg char(80) options(*varsize) const;
@i_dest int(10) const; // 1=Inter, 2=JobLog
end-pr;
With the call looking like this:
@i_Msg = 'No files waiting to be processed (STAT_10) in ECP308';
WriteMessage( @i_Msg : @c_ToJobLog );
We did stumble across a definition that does NOT define the message
parameter as being constant OR varying. If that is true than our
program, which believes that it is constant, may use a memory
location that could partially overlap a variable believing that it
won't be changed when, in fact, it could be changed by the API and
thereby change the value of our variable.
Are we correct in our reasoning?
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.