Date: Wed, 15 Dec 2021 11:51:42 +0100 (CET) From: Ronald Klop via freebsd-current <freebsd-current@freebsd.org> To: Piper H <potthua@gmail.com> Cc: freebsd-current@freebsd.org Subject: Re: question on socket server Message-ID: <1412287950.345.1639565502579@localhost> In-Reply-To: <CA%2BGLnbiqXQDfMLovYgipiLjSvRSWk%2B1ukDrh779=zZDt3P2L7Q@mail.gmail.com> References: <CA%2BGLnbiqXQDfMLovYgipiLjSvRSWk%2B1ukDrh779=zZDt3P2L7Q@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
------=_Part_344_414513860.1639565502522 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Hi, Just try it! I think you will get an error that you are writing to a not-connected socket. >From "man 2 write": " [EPIPE] An attempt is made to write to a socket of type SOCK_STREAM that is not connected to a peer socket." See also "man 2 send" and "man 2 socket" for a lot more information. So it depends a bit on the type of socket you created. Regards and happy hacking, Ronald. Van: Piper H <potthua@gmail.com> Datum: woensdag, 15 december 2021 07:52 Aan: freebsd-current@freebsd.org Onderwerp: question on socket server > > Hello > > I have little knowledge about socket programming. > I have a question that, if I have made a socket server, listening on a > port. The server prints data to the socket, but there is never a client > connection to the port, and the data is never consumed. What will happen to > the server then? will the OS kernel be flushed by junk bytes? > > Thanks for your help. > Piper > > > ------=_Part_344_414513860.1639565502522--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1412287950.345.1639565502579>