mIRC Home    About    Download    Register    News    Help

Print Thread
$portfree problem, seems to be win98 only #64674 21/12/03 08:19 AM
Joined: Dec 2003
Posts: 3
L
llyama Offline OP
Self-satisified door
OP Offline
Self-satisified door
L
Joined: Dec 2003
Posts: 3
if i create a TCP socket connection on port 8861 on my winxp box and do $portfree(8861) it returns $false

but doing the exact same on my win98 box, same script, it returns $true, even though the socket shows connected on that port using /socklist and netstat.

although when i create a listen socket on the port it then returns $false

using 6.12 mirc

Re: $portfree problem, seems to be win98 only #64675 21/12/03 08:02 PM
Joined: Dec 2002
Posts: 19
M
MiSsInGnO Offline
Pikka bird
Offline
Pikka bird
M
Joined: Dec 2002
Posts: 19
ahem, i don't see where the problem is...

$portfree is supposed to return whetera port is free ($true) or not ($false). In the case you describe on WinXP, it works properly (ie: returns $false when the port is in use). Other than that, i think that the value returned by $portfree may depend on several factors which may explain why it returns $true on Win98 while it SHOULDN'T! blush

Re: $portfree problem, seems to be win98 only #64676 22/12/03 04:43 AM
Joined: Dec 2003
Posts: 3
L
llyama Offline OP
Self-satisified door
OP Offline
Self-satisified door
L
Joined: Dec 2003
Posts: 3
yes i know it works correctly on windows xp, but on 98 it seems to return incorrect results and i can't see a pattern to it

Re: $portfree problem, seems to be win98 only #64677 27/12/03 03:28 PM
Joined: Jan 2003
Posts: 428
P
PastMaster Offline
Fjord artisan
Offline
Fjord artisan
P
Joined: Jan 2003
Posts: 428
A while ago I found I was getting problems with $portfree on Win98 as well - IIRC it was basically only recognising whether or not ports were used by mIRC or the usual Windows services, and not correctly recognising port usage by other applications.

I'd provide more details, but this was several versions ago, and in the end I found a workaround for what I wanted to do anyway... so it had slipped from my mind until I saw this thread. (Sorry! blush)

PM


IRCnet & DALnet @#travelersinn
:-: IRC for fun and relaxation :-: