|
>Date: Tue, 28 Nov 2000 10:48:58 -0600 >From: Mark Drazic <Mark.Drazic@Omniumww.com> > >In my testing, RPG is NOT very forgiving about passing pointers outside the >program object- it does not seem to allow this at all. There is mention of >it in the manuals somewhere, where memory can only be shared by modules of >the same program. You will especially have problems if the programs exists >in different Activation Groups. Mark, could you give examples, please? My own testing shows that RPG does allow pointers to be passed between programs and activation groups. Here's one scenario where you will have problems with pointers and activation groups: step 1: pgm1 in actgrp1 calls pgm2 in actgrp2, passing it a pointer to some storage in pgm1, or some allocated storage from actgrp1. step 2: pgm2 saves the pointer step 3: actgrp1 is ended step 4: pgm2 is called again and tries to use the pointer to access the storage (which has been destroyed along with the activation group) Otherwise, I'm not aware of any obstacles to passing pointers between programs or activation groups. Barbara Morris +--- | This is the RPG/400 Mailing List! | To submit a new message, send your mail to RPG400-L@midrange.com. | To subscribe to this list send email to RPG400-L-SUB@midrange.com. | To unsubscribe from this list send email to RPG400-L-UNSUB@midrange.com. | Questions should be directed to the list owner/operator: david@midrange.com +---
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.