comp.lang.ada
 help / color / mirror / Atom feed
* POSIX.Semaphores question
@ 2011-12-02 15:43 awdorrin
  2011-12-02 16:54 ` awdorrin
  2011-12-03 19:59 ` Niklas Holsti
  0 siblings, 2 replies; 12+ messages in thread
From: awdorrin @ 2011-12-02 15:43 UTC (permalink / raw)


I'm using the Florist POSIX Libraries and have code that is similar to
the following:

In the spec file:

Sem_READY : Semaphore;
READY         : Semaphore_Descriptor;
pragma Export( Ada, READY, "ready");

Then in my body:

POSIX.Semaphores.Initialize( Sem_READY, 1);
READY := POSIX.Semaphores.Descriptor_Of( Sem_READY );

When executed, READY is always set to null.

If I run the code through GDB and print READY, it always displays 0x0.
However, if I call POSIX.Semaphores.Descriptor_Of( Sem_Ready )
I get the right address returned: (access posix.c.sem_t) 0x8321540

I have no idea why the assignment is failing and not generating an
exception....



^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2011-12-06  0:53 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-12-02 15:43 POSIX.Semaphores question awdorrin
2011-12-02 16:54 ` awdorrin
2011-12-02 17:06   ` Georg Bauhaus
2011-12-02 17:09     ` Georg Bauhaus
2011-12-02 17:22       ` awdorrin
2011-12-03 16:32         ` awdorrin
2011-12-03 19:59 ` Niklas Holsti
2011-12-05 12:25   ` awdorrin
2011-12-05 14:19     ` Georg Bauhaus
2011-12-05 16:58       ` awdorrin
2011-12-05 17:59         ` Simon Wright
2011-12-06  0:53           ` awdorrin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox