[fpc-pascal] why connect is "deprecated"

Jonas Maebe jonas.maebe at elis.ugent.be
Tue Apr 16 13:08:24 CEST 2013

On 16 Apr 2013, at 12:13, Marco van de Voort wrote:

> In our previous episode, Jonas Maebe said:
>> As far as I can see, all errors are returned via inoutres/IOResult in
>> the same way as happens with disk-based IO.
> Yes. An attempt is made to map some of the errors to I/O. Anyway, if  
> sb
> wants to support and modernize them, I have no problem with that.  
> But that
> hasn't happened since 2005-2007 or so.

What needs to be modernised about it? It's not like our disk i/o error  
code handles many more different error codes, nor are those errors  
much more specific. I remember the old discussion, but I never  
understood how the error reporting of the sockets code and the generic  
I/O code differed in a way that made the former worse than the latter.

> That would also make it possible to directly map socketerror to
> getlastresult/fpgeterrno, instead of caching it in another threadvar.

IIRC the problem with removing socketerror would be that it could  
easily break existing code (given that socketerror is not overwritten  
by calls other than those from the sockets unit).


More information about the fpc-pascal mailing list