Re: [fpc-pascal] Socket pair

2016-10-04 Thread Paul Breneman
On 10/03/2016 07:24 AM, Paul Breneman wrote: On 10/03/2016 03:27 AM, Santiago A. wrote: I've seen that "accept" functions with socket pairs are deprecated. And fpsocketpair returns always -1. How do you get the in and out streams when a server accepts a new client connection? I have seen some

Re: [fpc-pascal] Socket pair

2016-10-03 Thread Mark Morgan Lloyd
On 03/10/16 12:00, Michael Van Canneyt wrote: On Mon, 3 Oct 2016, Santiago A. wrote: can anyone point and example with pair of sockets or bidirectional connection communication? The same socket descriptor (stream, if you want) can be used for reading and writing. The descriptor uses differen

Re: [fpc-pascal] Socket pair

2016-10-03 Thread Paul Breneman
On 10/03/2016 03:27 AM, Santiago A. wrote: I've seen that "accept" functions with socket pairs are deprecated. And fpsocketpair returns always -1. How do you get the in and out streams when a server accepts a new client connection? I have seen some server examples, like isocksrv.pp, but only re

Re: [fpc-pascal] Socket pair

2016-10-03 Thread Michael Van Canneyt
On Mon, 3 Oct 2016, Santiago A. wrote: I've seen that "accept" functions with socket pairs are deprecated. And fpsocketpair returns always -1. How do you get the in and out streams when a server accepts a new client connection? I have seen some server examples, like isocksrv.pp, but only rea

Re: [fpc-pascal] Socket pair

2016-10-03 Thread Michael Van Canneyt
On Mon, 3 Oct 2016, Rainer Stratmann wrote: There is fpaccept http://www.freepascal.org/docs-html/rtl/sockets/fpaccept.html But in the example accept is used ... (?!) Can you please report this in the bugtracker so I do not forget to correct this ? Michael. Am Montag, 3. Oktober 2016,

Re: [fpc-pascal] Socket pair

2016-10-03 Thread Rainer Stratmann
There is fpaccept http://www.freepascal.org/docs-html/rtl/sockets/fpaccept.html But in the example accept is used ... (?!) Am Montag, 3. Oktober 2016, 10:27:55 schrieb Santiago A.: > I've seen that "accept" functions with socket pairs are deprecated. And > fpsocketpair returns always -1. > > H

[fpc-pascal] Socket pair

2016-10-03 Thread Santiago A.
I've seen that "accept" functions with socket pairs are deprecated. And fpsocketpair returns always -1. How do you get the in and out streams when a server accepts a new client connection? I have seen some server examples, like isocksrv.pp, but only read from client and send nothing back to clien