Yikes. This isn't terribly readable. Try:

    data << "Hello, " << ip << ":" << port << "!<br>"
         << "<b>Header count: " << request.headers.size(); << "</b><br>";