🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: Would Indy's TIdTCPServer have any problem with connections I never read from?

#2075
From: Lesley Anne
Date: Thu, 31 Aug 2006 15:51
18 lines
2275 bytes
> It does not matter what class the OnExecute event handler is
> DECLARED in. The OnExecute event handler (and any other event
> handler that provides access to the connection's thread/context)
> is TRIGGERED in the context of the worker thread that is
> managing the connection.  It is NOT triggered in the context
> of the thread that owns the TIdTCPServer.

Thanks for the explanation.  (That's something that I wish the help file had 
explained.)  It works well here for reading, but now it looks like I'm going 
to have to change my OnException and OnListenException handlers, if they 
take place within their respective threads as well.

I've worked occasionally with secondary threads I wrote myself (as TThread 
descendants), so in that type of case I know how to send messages from a 
secondary thread back to my main thread using thread-global variables and 
Synchronize().  I'm not sure how to do it here though, where I don't have 
access to adding variables to the thread class.  How would I send a String, 
for instance, back to my main form from within one of these event handlers?
Technical Details
Message-ID: <44f70595$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news1.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <44f480ff@newsgroups.borland.com> <44f49d01$1@newsgroups.borland.com> <44f5c67a$1@newsgroups.borland.com> <44f5e682$1@newsgroups.borland.com> <44f5ef4f@newsgroups.borland.com> <44f6068c$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,c51ec25c5d4e68e1
X-Google-Attributes: gid11508e,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Lesley Anne" <mspfila-ng@yahoo.com>
Newsgroups: borland.public.cppbuilder.internet.socket
References: <44f480ff@newsgroups.borland.com> <44f49d01$1@newsgroups.borland.com> <44f5c67a$1@newsgroups.borland.com> <44f5e682$1@newsgroups.borland.com> <44f5ef4f@newsgroups.borland.com> <44f6068c$1@newsgroups.borland.com>
Subject: Re: Would Indy's TIdTCPServer have any problem with connections I never read from?
Date: Thu, 31 Aug 2006 11:51:42 -0400
Lines: 20
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2869
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2962
X-RFC2646: Format=Flowed; Original
NNTP-Posting-Host: 144.160.5.25
Message-ID: <44f70595$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1157039509 144.160.5.25 (31 Aug 2006 08:51:49 -0700)
Path: arc1-ca.pugleaf.net!g2news2.google.com!news1.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail