mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
Update SRS3
This commit is contained in:
commit
acaae0d5c9
4 changed files with 10 additions and 5 deletions
|
@ -27,7 +27,7 @@
|
|||
// current release version
|
||||
#define VERSION_MAJOR 3
|
||||
#define VERSION_MINOR 0
|
||||
#define VERSION_REVISION 42
|
||||
#define VERSION_REVISION 44
|
||||
|
||||
// generated by configure, only macros.
|
||||
#include <srs_auto_headers.hpp>
|
||||
|
|
|
@ -356,10 +356,10 @@ string srs_erase_first_substr(string str, string erase_string)
|
|||
|
||||
size_t pos = ret.find(erase_string);
|
||||
|
||||
if (pos != std::string::npos)
|
||||
{
|
||||
if (pos != std::string::npos) {
|
||||
ret.erase(pos, erase_string.length());
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
@ -369,10 +369,10 @@ string srs_erase_last_substr(string str, string erase_string)
|
|||
|
||||
size_t pos = ret.rfind(erase_string);
|
||||
|
||||
if (pos != std::string::npos)
|
||||
{
|
||||
if (pos != std::string::npos) {
|
||||
ret.erase(pos, erase_string.length());
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
|
@ -63,6 +63,10 @@ void srs_vhost_resolve(string& vhost, string& app, string& param)
|
|||
app = srs_string_replace(app, "&&", "?");
|
||||
app = srs_string_replace(app, "=", "?");
|
||||
|
||||
if (srs_string_ends_with(app, "/_definst_")) {
|
||||
app = srs_erase_last_substr(app, "/_definst_");
|
||||
}
|
||||
|
||||
if ((pos = app.find("?")) != std::string::npos) {
|
||||
std::string query = app.substr(pos + 1);
|
||||
app = app.substr(0, pos);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue