comp.lang.ada
 help / color / mirror / Atom feed
From: Simon Wright <simon@pogner.demon.co.uk>
Subject: Re: Sockets in Apex
Date: 2000/02/12
Date: 2000-02-12T00:00:00+00:00	[thread overview]
Message-ID: <x7v1z6idgkr.fsf@pogner.demon.co.uk> (raw)
In-Reply-To: 87s92v$lke$1@nnrp1.deja.com

reason67@my-deja.com writes:

> I wrote a socket binding to Ada 95. I am creating an executable in Apex
> 3.2.0b on Solaris 2.6.
> 
> When I connect a non-blocking client socket in a task in the threaded
> model, errno does not seem to be set by the underlying C. When I run in
> the non-threaded model, or I connect the client without any tasks (just
> the main), or I make the socket block, everything works fine.

I take it the "underlying C" is yours? have you compiled it with
-D_REENTRANT ? (I _think_ that's the Solaris way of saying the
compiler should pick up the thread-aware version of errno and others).

From the Linux <errno.h>,

  #if defined(_POSIX_THREAD_SAFE_FUNCTIONS) || defined(_REENTRANT)
  extern int*	__errno_location  __P((void));
  #define errno	(*__errno_location ())
  #else
  extern int errno;
  #endif




      parent reply	other threads:[~2000-02-12  0:00 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-02-09  0:00 Sockets in Apex reason67
2000-02-09  0:00 ` Jim Rogers
2000-02-09  0:00 ` Ted Dennison
2000-02-12  0:00 ` Simon Wright [this message]
replies disabled

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