MCPcopy Create free account
hub / github.com/BigPig0/RelayLive / WriteFailResponse

Method WriteFailResponse

Projects/live_server/server.cpp:412–425  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

410 }
411
412 void CLiveSession::WriteFailResponse() {
413 stringstream ss;
414 ss << version << " 400 Bad request\r\n"
415 "Connection: " << Connection << "\r\n"
416 "Content-Length: 0\r\n"
417 "\r\n";
418
419 writeBuff.clear();
420 writeBuff.append_string(ss.str().c_str());
421
422 writing = true;
423 uv_buf_t buff = uv_buf_init(writeBuff.get(), writeBuff.size());
424 uv_write(&writeReq, (uv_stream_t*)&socket, &buff, 1, on_uv_write);
425 }
426
427 //////////////////////////////////////////////////////////////////////////
428

Callers

nothing calls this directly

Calls 5

uv_buf_initFunction · 0.85
append_stringMethod · 0.80
uv_writeFunction · 0.50
getMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected