Boost logo

Boost :

Subject: Re: [boost] Problem with ASIO
From: Bjorn Reese (breese_at_[hidden])
Date: 2016-02-10 06:54:35


On 02/10/2016 02:27 AM, Juan Dent wrote:

> posix::stream_descriptor stream{ioservice, STDOUT_FILENO};

Here you take over ownership of stdout, so it will be closed by the
stream destructor. A quick fix is to pass a copy of the file descriptor
with ::dup(STDOUT_FILENO) as shown in the posix_chat_client.cpp example.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk