× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.




On 16/05/2009, at 5:23 AM, Dan Kimmel wrote:

MCH3601 is "Pointer not set for location referenced." It is a common
programming mistake. Trying to dereference a pointer that hasn't been
set. (In i, "not set" is different than null.)

Don't think so. A null pointer has not been set to an address. That's all MCH3601 is complaining about. Perhaps you are thinking of an "unresolved" system pointer (which is essentially also "not set" but because the pointer type is known a different message can be sent)?

One might question why "Pointer not set for location referenced" is used instead of a more obvious message. The code referenced a storage location that was expected to contain a pointer but it didn't have a valid address. Second-guessing the designers here but it seems to me that you could have a pointer chain in which one of the pointers was not set. How do you indicate a pointer buried in the chain is not set? In this case the "location referenced" would refer to the last good pointer and that it is pointing to an un-set pointer.


So probably the problem is in your code.

That is the most likely explanation for MCH3601 errors. We really need to be told the "from program" and "to program" values from the exception to know where to start looking.


QMHSNDM, as most system API's takes pointers for parameters. I'm not
sure if the command interpreter (invoked through "system") is going to
resolve all your constants into pointers.

Highly unlikely that 'system' is the program. The QMHSNDM API can be called from the command line and via QCMDEXC. 'system' is simply another interface to QCMDEXC. In all cases the real work is done by the CALL command.

Also, I'd be interested to see if tht printf was actually producing what you intend.


Yes, that's a useful diagnosis step: See if the final formatted command looks like a properly formatted OS/400 command.

Regards,
Simon Coulter.
--------------------------------------------------------------------
FlyByNight Software OS/400, i5/OS Technical Specialists

http://www.flybynight.com.au/
Phone: +61 2 6657 8251 Mobile: +61 0411 091 400 /"\
Fax: +61 2 6657 8251 \ /
X
ASCII Ribbon campaign against HTML E-Mail / \
--------------------------------------------------------------------




As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.