Re: Shared memory?

New Message Reply Date view Thread view Subject view Author view

Amaury Aubel (aubel++at++lig.di.epfl.ch)
Tue, 27 May 1997 11:44:41 -0600


> > that spawns a database process. In the database process various structures
are
> > allocated from the shared arena using pfMalloc(..., pfGetSharedArena()).
> > Yet when the app. process attempts to access a particular variable it is
> > undefined and the application crashes.
>
>
> Just a wild guess...
>
> How do you declare the variable? Is it inside a structure that was
> pfMalloc'ed before you spawned the database process ? If not this
> is normal behavior: The variable will point to the right address in
> the database process but will still point to something random in the
> application process (unless you write nice programs and initialized the
> pointer to NULL)

Thanks for your hint but - alas - it is not the case.
To be accurate I have an array of structures. It used to be declared as
follows:

MYSTRUCT *ModelList[NB_MAX];
with each element being pfMalloc'ed in the dabse process. I changed it later
to:

MYSTRUCT **ModelList;
and now the list too is pfMalloc'ed in the dbase process. However when
debugging I found out that ModelList is NULL in the application process. How
come?

Amaury.

-- 
+----------------------------------------------------------------------+

Amaury Aubel aubel++at++lig.di.epfl.ch EPFL-LIG, 1015 Lausanne/Switzerland Fax: +41 21 693 53 28 Swiss Federal Institute of technology, Computer Graphics Lab

+----------------------------------------------------------------------+

======================================================================= List Archives, FAQ, FTP: http://www.sgi.com/Technology/Performer/ Submissions: info-performer++at++sgi.com Admin. requests: info-performer-request++at++sgi.com


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:55:18 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.