mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
for #133, support the rtsp options request and response.
This commit is contained in:
parent
c0e50265bd
commit
604f4cc57b
8 changed files with 849 additions and 33 deletions
|
@ -76,13 +76,13 @@ int SrsHttpClient::post(SrsHttpUri* uri, string req, int& status_code, string& r
|
|||
// POST %s HTTP/1.1\r\nHost: %s\r\nContent-Length: %d\r\n\r\n%s
|
||||
std::stringstream ss;
|
||||
ss << "POST " << uri->get_path() << " "
|
||||
<< "HTTP/1.1" << __SRS_CRLF
|
||||
<< "Host: " << uri->get_host() << __SRS_CRLF
|
||||
<< "Connection: Keep-Alive" << __SRS_CRLF
|
||||
<< "Content-Length: " << std::dec << req.length() << __SRS_CRLF
|
||||
<< "User-Agent: " << RTMP_SIG_SRS_NAME << RTMP_SIG_SRS_VERSION << __SRS_CRLF
|
||||
<< "Content-Type: application/json" << __SRS_CRLF
|
||||
<< __SRS_CRLF
|
||||
<< "HTTP/1.1" << __SRS_HTTP_CRLF
|
||||
<< "Host: " << uri->get_host() << __SRS_HTTP_CRLF
|
||||
<< "Connection: Keep-Alive" << __SRS_HTTP_CRLF
|
||||
<< "Content-Length: " << std::dec << req.length() << __SRS_HTTP_CRLF
|
||||
<< "User-Agent: " << RTMP_SIG_SRS_NAME << RTMP_SIG_SRS_VERSION << __SRS_HTTP_CRLF
|
||||
<< "Content-Type: application/json" << __SRS_HTTP_CRLF
|
||||
<< __SRS_HTTP_CRLF
|
||||
<< req;
|
||||
|
||||
SrsStSocket skt(stfd);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue