The read is not slow, you just forgot to specify the close header:
request_stream << "Connection: close\r\n";
This makes the process swift.
Note that the debug output wasn't 'instantaneous' due to buffering, try
std::cout.setf(std::ios::unitbuf);