comp.lang.ada
 help / color / mirror / Atom feed
From: frederic.ormancey@atosorigin.com (Fr?d?ric Ormancey)
Subject: Select return code not used in Check_Selector
Date: 10 Sep 2004 02:15:13 -0700
Date: 2004-09-10T02:15:13-07:00	[thread overview]
Message-ID: <9c9fb8b4.0409100115.7ecea6b2@posting.google.com> (raw)

In g-socket.adb / Check_Selector function, the ret code of C_Select
call is not used. This cause erroneous R or W socket set to be
processed by the caller, or in me particular case, an exit with ABORT
status ( R_Sig_Socket flag is set )

Normally, C_select() will reset the bits socket sets so that only
those sockets that are ready will have bits set.  However, when an
error occurs, the bit set remains as it was when the select call was
first made.

Testing the C_Select ret code will avoid erroneous processing of
sockets which are not really set. Perhaps Check_Selector can then
return a specific ERROR status to be added in Selector_Status type.

I detect the problem with GNAT 3.17 on Linux RedHat 7.2 platform.



                 reply	other threads:[~2004-09-10  9:15 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed
replies disabled

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