Article View: borland.public.cppbuilder.internet.socket
Article #1832Re: Can I check for invalid TCustomWinSocket pointers?
From: Remy Lebeau (TeamB)
Date: Mon, 09 Oct 2006 19:40
Date: Mon, 09 Oct 2006 19:40
15 lines
1540 bytes
1540 bytes
"Lesley Anne" <mspfila-ng@yahoo.com> wrote in message news:452a8c67$1@newsgroups.borland.com... > I'd like to be able to check whether my TCustomWinSocket* still > points to a valid active socket before I try sending the response to it. > Is there a good way to do that? The only way to validate the pointer is to see if it still exists in the server's Connection's list. Otherwise, you will have to update your code to set your stored pointers to NULL when the OnDisconnect event occurs, and then have your database code check for NULL before writing to the socket. Gambit
Technical Details
Message-ID:
<452aa627$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news2.google.com!news4.google.com!news3.google.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newspeer1.nwr.nac.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mailReferences:
<452a8c67$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,f9dc4bb901912d81 X-Google-Attributes: gid11508e,public X-Google-Language: ENGLISH,ASCII-7-bit From: "Remy Lebeau \(TeamB\)" <no.spam@no.spam.com> Newsgroups: borland.public.cppbuilder.internet.socket References: <452a8c67$1@newsgroups.borland.com> Subject: Re: Can I check for invalid TCustomWinSocket pointers? Date: Mon, 9 Oct 2006 12:40:29 -0700 Lines: 17 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1409 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409 NNTP-Posting-Host: 69.169.4.232 Message-ID: <452aa627$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1160422951 69.169.4.232 (9 Oct 2006 12:42:31 -0700) Path: arc1-ca.pugleaf.net!g2news2.google.com!news4.google.com!news3.google.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newspeer1.nwr.nac.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail