Progress on preventing multiple instances of a programfromrunning in windows

Lynch, Jonathan BNZ2 at CDC.GOV
Fri Dec 3 13:17:53 EST 2004


What I am finding is that it is forcing the TCP listen without even
using the accept command. The following script:

Open socket to "127.0.0.1:48953"
Write "Greetings" to socket "127.0.0.1:48953"
Close socket "127.0.0.1:48953"

Causes the instance that ran this script to start listening to port
48953. Shouldn't it only do that if the script actually uses the accept
command?

-----Original Message-----
From: use-revolution-bounces at lists.runrev.com
[mailto:use-revolution-bounces at lists.runrev.com] On Behalf Of Dar Scott
Sent: Friday, December 03, 2004 1:12 PM
To: How to use Revolution
Subject: Re: Progress on preventing multiple instances of a
programfromrunning in windows


On Dec 3, 2004, at 10:59 AM, Lynch, Jonathan wrote:

> My understanding of ports and sockets is weak - but shouldn't it be 
> able
> to write to socket "127.0.0.1:48953" without setting itself up as
> listening to port 48953?

If any application on the computer is listening on that port, then then 
a connection to it can be opened.

There are less constraints for UDP.

The particular "feature" that came up is that on some OSes, Rev seems 
to force a TCP listen (Rev accept) to succeed even then there is a 
clash.  As Alex Tweedly showed (that is, as I interpret his results), 
other apps typically do not do this.

Dar
****************************************
     Dar Scott Consulting
     http://www.swcp.com/dsc/
     Programming Services
****************************************

_______________________________________________
use-revolution mailing list
use-revolution at lists.runrev.com
http://lists.runrev.com/mailman/listinfo/use-revolution


More information about the use-livecode mailing list