From: Simon Wright <simon.j.wright@mac.com>
Subject: Re: GNAT.Sockets: Timeval_Duration is in milliseconds?
Date: Mon, 10 Dec 2007 20:06:53 +0000
Date: 2007-12-10T20:06:53+00:00 [thread overview]
Message-ID: <m2tzmqgvqa.fsf@mac.com> (raw)
In-Reply-To: ffe83e08-568a-417d-bae0-f8a1b71a25fa@w56g2000hsf.googlegroups.com
gpriv@axonx.com writes:
> I use GPS 4.1.3 (20070913), GNAT GPL 2007 (20070405-41)
>
> It may be good idea to fix windows version of GNAT though.
GNAT 6.0.1 handles this program properly on Windows XP ..
with Ada.Calendar;
with Ada.Text_IO; use Ada.Text_IO;
with GNAT.Sockets;
procedure Socket_Times is
Sel : GNAT.Sockets.Selector_Type;
R, W : GNAT.Sockets.Socket_Set_Type;
Stat : GNAT.Sockets.Selector_Status;
Start, Finish : Ada.Calendar.Time;
use type Ada.Calendar.Time;
begin
GNAT.Sockets.Initialize;
GNAT.Sockets.Create_Selector (Sel);
Put_Line ("starting..");
Start := Ada.Calendar.Clock;
GNAT.Sockets.Check_Selector (Sel, R, W, Stat, 5.0);
Finish := Ada.Calendar.Clock;
Put_Line ("..done with "
& Stat'Img
& " after "
& Duration'Image (Finish - Start));
end Socket_Times;
(I don't have the output here, but it printed
..done with EXPIRED after 5.0001
or thereabouts, same as GPL 2006 on Mac OS X).
Anyone care to try this on other Windows GNAT compiler releases?
next prev parent reply other threads:[~2007-12-10 20:06 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-12-08 19:45 GNAT.Sockets: Timeval_Duration is in milliseconds? gpriv
2007-12-08 22:11 ` Simon Wright
2007-12-08 22:34 ` gpriv
2007-12-09 1:45 ` tmoran
2007-12-09 9:33 ` Dmitry A. Kazakov
2007-12-09 12:50 ` Gautier
2007-12-09 13:37 ` Dmitry A. Kazakov
2007-12-09 14:59 ` Martin Krischik
2007-12-09 17:24 ` Dmitry A. Kazakov
2007-12-09 15:55 ` gpriv
2007-12-09 17:25 ` Dmitry A. Kazakov
2007-12-09 18:26 ` Simon Wright
2007-12-09 19:36 ` gpriv
2007-12-09 22:51 ` Simon Wright
2007-12-09 23:27 ` gpriv
2007-12-10 20:06 ` Simon Wright [this message]
2007-12-10 21:02 ` gpriv
2007-12-11 20:33 ` Simon Wright
2007-12-13 3:44 ` gpriv
2007-12-13 13:13 ` Simon Wright
2007-12-13 14:32 ` gpriv
2007-12-09 19:46 ` tmoran
2007-12-09 9:01 ` Martin Krischik
2007-12-09 9:32 ` Dmitry A. Kazakov
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox