|
|
|
@ -325,6 +325,8 @@ SrsHttpMessage::SrsHttpMessage(ISrsReader* reader, SrsFastStream* buffer) : ISrs
|
|
|
|
|
// From HTTP/1.1, default to keep alive.
|
|
|
|
|
_keep_alive = true;
|
|
|
|
|
type_ = 0;
|
|
|
|
|
|
|
|
|
|
schema_ = "http";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
SrsHttpMessage::~SrsHttpMessage()
|
|
|
|
@ -416,7 +418,8 @@ srs_error_t SrsHttpMessage::set_url(string url, bool allow_jsonp)
|
|
|
|
|
|
|
|
|
|
void SrsHttpMessage::set_https(bool v)
|
|
|
|
|
{
|
|
|
|
|
_uri->set_schema(v? "https" : "http");
|
|
|
|
|
schema_ = v? "https" : "http";
|
|
|
|
|
_uri->set_schema(schema_);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
ISrsConnection* SrsHttpMessage::connection()
|
|
|
|
@ -429,6 +432,11 @@ void SrsHttpMessage::set_connection(ISrsConnection* conn)
|
|
|
|
|
owner_conn = conn;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
string SrsHttpMessage::schema()
|
|
|
|
|
{
|
|
|
|
|
return schema_;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
uint8_t SrsHttpMessage::method()
|
|
|
|
|
{
|
|
|
|
|
if (jsonp && !jsonp_method.empty()) {
|
|
|
|
|