🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.internet.socket
Article #739

Re: EidClosedSocket with message 'Disconnected'

#739
From: Remy Lebeau (TeamB)
Date: Mon, 26 Nov 2007 17:35
20 lines
1762 bytes
"SKLIM" <sklim82@hotmail.com> wrote in message 
news:474a9a54$1@newsgroups.borland.com...

> I am using Indy 9.0.4. Currently I am working on TCPServer and
> facing problem to disconnect all connected client.

That is because you are disconnecting them wrong.  You are closing the 
Binding itself, not the clients that are connected to it.  You would have to 
loop through the entries in the server's ActiveThreads list, calling 
DisconnectSocket() on each one individually.

> Any suggestion to gracefully disconnect all connected clients?

You should not be disconnecting them manually to begin with.  Setting the 
Active property to false by itself will internally disconnect all active 
clients for you.


Gambit 
Technical Details
Message-ID: <474b043f$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!proxad.net!feeder1-2.proxad.net!213.200.89.82.MISMATCH!tiscali!newsfeed1.ip.tiscali.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <474a9a54$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,8ed7ff271444a626
X-Google-Attributes: gid11508e,public,usenet
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Remy Lebeau \(TeamB\)" <no.spam@no.spam.com>
Newsgroups: borland.public.cppbuilder.internet.socket
References: <474a9a54$1@newsgroups.borland.com>
Subject: Re: EidClosedSocket with message 'Disconnected'
Date: Mon, 26 Nov 2007 09:35:46 -0800
Lines: 22
Organization: Lebeau Software
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.3138
X-RFC2646: Format=Flowed; Original
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3198
NNTP-Posting-Host: 207.178.157.90
Message-ID: <474b043f$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1196098623 207.178.157.90 (26 Nov 2007 09:37:03 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!proxad.net!feeder1-2.proxad.net!213.200.89.82.MISMATCH!tiscali!newsfeed1.ip.tiscali.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail