crossroads

Git mirror of https://crossroads.e-tunity.com/
git clone git://git.finwo.net/app/crossroads
Log | Files | Refs | LICENSE

answerblob.cc (388B)


      1 #include "webinterface"
      2 
      3 void Webinterface::answer_blob (string const &blob) {
      4     ostringstream cl;
      5     cl << blob.size();
      6     string resp = static_cast<string>
      7        ("HTTP/1.0 200 OK\r\n") +
      8 	"Content-Type: text/xml\r\n"
      9 	"Connection: close\r\n"
     10 	"Content-Length: " + cl.str() + "\r\n"
     11 	"\r\n" +
     12 	blob;
     13     Netbuffer buf(resp);
     14     buf.netwrite(cfd, config.client_write_timeout());
     15 }