mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
Micro changes and refines.
This commit is contained in:
parent
173c683566
commit
378bffa34f
20 changed files with 110 additions and 119 deletions
|
@ -489,7 +489,7 @@ void SrsUnSortedHashtable::set(string key, SrsAmf0Any* value)
|
|||
|
||||
if (key == name) {
|
||||
srs_freep(any);
|
||||
properties.erase(it);
|
||||
it = properties.erase(it);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -14,6 +14,11 @@ ISrsResource::~ISrsResource()
|
|||
{
|
||||
}
|
||||
|
||||
std::string ISrsResource::desc()
|
||||
{
|
||||
return "Resource";
|
||||
}
|
||||
|
||||
ISrsResourceManager::ISrsResourceManager()
|
||||
{
|
||||
}
|
||||
|
|
|
@ -21,7 +21,7 @@ public:
|
|||
// Get the context id of connection.
|
||||
virtual const SrsContextId& get_id() = 0;
|
||||
// The resource description, optional.
|
||||
virtual std::string desc() = 0;
|
||||
virtual std::string desc();
|
||||
};
|
||||
|
||||
// The manager for resource.
|
||||
|
|
|
@ -19,6 +19,7 @@ using namespace std;
|
|||
#include <srs_core_autofree.hpp>
|
||||
#include <srs_protocol_rtmp_stack.hpp>
|
||||
#include <srs_protocol_conn.hpp>
|
||||
#include <srs_protocol_http_stack.hpp>
|
||||
|
||||
SrsHttpParser::SrsHttpParser()
|
||||
{
|
||||
|
@ -451,24 +452,8 @@ string SrsHttpMessage::method_str()
|
|||
if (jsonp && !jsonp_method.empty()) {
|
||||
return jsonp_method;
|
||||
}
|
||||
|
||||
if (is_http_get()) {
|
||||
return "GET";
|
||||
}
|
||||
if (is_http_put()) {
|
||||
return "PUT";
|
||||
}
|
||||
if (is_http_post()) {
|
||||
return "POST";
|
||||
}
|
||||
if (is_http_delete()) {
|
||||
return "DELETE";
|
||||
}
|
||||
if (is_http_options()) {
|
||||
return "OPTIONS";
|
||||
}
|
||||
|
||||
return "OTHER";
|
||||
|
||||
return http_method_str((http_method)_method);
|
||||
}
|
||||
|
||||
bool SrsHttpMessage::is_http_get()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue