C (221/254)

From:Jesper Svennevid
Date:03 Apr 00 at 19:20:09
Subject:RE: TCP online

> From: mike.carter@ukonline.co.uk
>
> Hi,
>
> What is the easiest way to check if a user has his machine
> currently online or not? Not matter what TCP/IP stack (s)he
> is using?
>
> Would it be okay to attempt to open the bsdsocket.library (is
> this also made available from miami?) and then call some
> common function in that?

It's not as easy as it seems, as "being online" may differ
depending on what interfaces that are enabled. For example,
AmiTCP and MiamiDx allows you to be connected to several
nets at once, so you can't tell if you're online, you can
only see if you can reach a specific host.

I open bsdsocket.library only on demand, and tries to connect.
If it doesn't work, I'm not online, or something else might
be interfering (my ISP goes bust, a router bursts into flames,
etc etc)



// Jesper Svennevid : jesper@fxrealm.com
Software Developer at FXRealm Studios
http://www.fxrealm.com/

------------------------------------------------------------------------
PERFORM CPR ON YOUR APR!
Get a NextCard Visa, in 30 seconds! Get rates as low as
0.0% Intro or 9.9% Fixed APR and no hidden fees.
Apply NOW!
http://click.egroups.com/1/2121/1/_/451227/_/954785989/
------------------------------------------------------------------------