|
Hello Richard, You wrote: >I might observe that the character string names in INTOBJNAME and INTLIBNAME >are null-terminated and that the INTOBJTYPE is blank filled. In the >context, the names are certain not to have any hex zeros in them so these >names won't find a hit in the context. I always set the type field to hex >zeros before stuffing in the type and subtype. I suppose that POINTER is >valid for the return value but I always used SYSPTR for those. Those values must be NULL-terminated for the C function to work correctly. You are correct with regard to the values in the contexts but by the time the values get to the MI instruction the NULL should have been removed by the C function. An RPG space pointer is not really valid to hold a SYP but it works because we never actually use the pointer, just pass it on to setsppfp() which expects a SYP . It doesn't actually care that it was declared as a space pointer. All pointers are 16 bytes and 16-byte aligned and although there are bit-pattern differences in the high-order bits this seemed to work. (It may just be using the 8-byte address portion and not care what type of pointer it receives.) The big caveat is of course that the setsppfp MI instruction will accept a SYP or a SPP (or DAP) and I did a fairly cursory check that the pointer returned by setsppfp() did reference the associated space. It may actually reference the object. Regards, Simon Coulter. «»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«» «» FlyByNight Software AS/400 Technical Specialists «» «» Eclipse the competition - run your business on an IBM AS/400. «» «» «» «» Phone: +61 3 9419 0175 Mobile: +61 0411 091 400 «» «» Fax: +61 3 9419 0175 mailto: shc@flybynight.com.au «» «» «» «» Windoze should not be open at Warp speed. «» «»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«» +--- | This is the MI Programmers Mailing List! | To submit a new message, send your mail to MI400@midrange.com. | To subscribe to this list send email to MI400-SUB@midrange.com. | To unsubscribe from this list send email to MI400-UNSUB@midrange.com. | Questions should be directed to the list owner/operator: dr2@cssas400.com +---
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.