🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: how to send buffer size message and buffer

#4944
From: Vladimir Stefanovic
Date: Fri, 19 Nov 2004 06:18
26 lines
1859 bytes
> It only applies to non-blocking sockets, which TClientSocket
> and TServerSocket are set it by default.

When TClientSocket is ctNonBlocking and TServerSocket is
stThreadBlocking, should I use that concept?

> You should always
> check for WSAEWOULDBLOCK when Send/ReceiveBuf() return -1.
> -1 means that a socket error occured, but WSAEWOULDBLOCK is
> a recoverable error.

Yes, I have read that immediately at Win32 Help.

> [...] You simply
> call Send/ReceiveBuf() again with the same parameters until
> the call finally succeeds without blocking, or until a true
> error occcurs.

Yes, and ProcessMessages() followed by continue can only
loop but cannot detect when the "true error occurs".



Best regards,
Vladimir Stefanovic
Technical Details
Message-ID: <419d9e5b$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!in.100proofnews.com!in.100proofnews.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail
References: <419b3068$1@newsgroups.borland.com> <419b32cf$1@newsgroups.borland.com> <419b934b$1@newsgroups.borland.com> <419cbb08$1@newsgroups.borland.com> <419cd9b2$1@newsgroups.borland.com> <419cf046@newsgroups.borland.com> <419cfe32$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,e51687cce2165a07
X-Google-Attributes: gid11508e,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Vladimir Stefanovic" <antivari@ptt.yu>
Sender: "Vladimir Stefanovic" <antivari@ptt.yu>
Reply-To: "Vladimir Stefanovic" <antivari@ptt.yu>
Subject: Re: how to send  buffer size message and buffer 
Newsgroups: borland.public.cppbuilder.internet.socket
X-User-Info: 213.137.116.151     
X-Forwarded-For: 128.128.129.165
References: <419b3068$1@newsgroups.borland.com> <419b32cf$1@newsgroups.borland.com> <419b934b$1@newsgroups.borland.com> <419cbb08$1@newsgroups.borland.com> <419cd9b2$1@newsgroups.borland.com> <419cf046@newsgroups.borland.com> <419cfe32$1@newsgroups.borland.com>
NNTP-Posting-Host: 207.105.83.66
Message-ID: <419d9e5b$1@newsgroups.borland.com>
Date: 18 Nov 2004 23:18:51 -0700
X-Trace: newsgroups.borland.com 1100848731 207.105.83.66 (18 Nov 2004 23:18:51 -0700)
Lines: 26
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!in.100proofnews.com!in.100proofnews.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail