Skip to content

Commit

Permalink
Merge #1077 from 2.0release
Browse files Browse the repository at this point in the history
  • Loading branch information
winlinvip committed Feb 28, 2018
2 parents c528b41 + 0fe17c3 commit 459272b
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 10 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,7 @@ Please select according to languages:

### V2 changes

* v2.0, 2018-02-28, Merge [#1077][bug #1077], fix crash for edge HLS. 2.0.247
* v2.0, 2018-02-13, Fix [#1059][bug #1059], support vhost in stream parameters. 2.0.246
* v2.0, 2018-01-07, Merge [#1045][bug #1045], fix [#1044][bug #1044], TCP connection alive detection. 2.0.245
* v2.0, 2018-01-04, Merge [#1039][bug #1039], fix bug of init.d script.
Expand Down Expand Up @@ -1430,6 +1431,7 @@ Winlin
[bug #1044]: https://github.com/ossrs/srs/issues/1044
[bug #1045]: https://github.com/ossrs/srs/issues/1045
[bug #1059]: https://github.com/ossrs/srs/issues/1059
[bug #1077]: https://github.com/ossrs/srs/issues/1077
[bug #xxxxxxxxxx]: https://github.com/ossrs/srs/issues/xxxxxxxxxx

[bug #735]: https://github.com/ossrs/srs/issues/735
Expand Down
2 changes: 1 addition & 1 deletion trunk/src/app/srs_app_hls.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1011,7 +1011,7 @@ srs_error_t SrsHls::initialize(SrsOriginHub* h, SrsRequest* r)
srs_error_t SrsHls::on_publish()
{
srs_error_t err = srs_success;

// update the hls time, for hls_dispose.
last_update_time = srs_get_system_time_ms();

Expand Down
14 changes: 7 additions & 7 deletions trunk/src/app/srs_app_rtmp_conn.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ srs_error_t SrsRtmpConn::do_cycle()

rtmp->set_recv_timeout(SRS_CONSTS_RTMP_TMMS);
rtmp->set_send_timeout(SRS_CONSTS_RTMP_TMMS);

if ((err = rtmp->handshake()) != srs_success) {
return srs_error_wrap(err, "rtmp handshake");
}
Expand Down Expand Up @@ -472,28 +472,28 @@ srs_error_t SrsRtmpConn::stream_service_cycle()
req->strip();
srs_trace("client identified, type=%s, vhost=%s, app=%s, stream_name=%s, duration=%.2f",
srs_client_type_string(info->type).c_str(), req->vhost.c_str(), req->app.c_str(), req->stream.c_str(), req->duration);

// discovery vhost, resolve the vhost from config
SrsConfDirective* parsed_vhost = _srs_config->get_vhost(req->vhost);
if (parsed_vhost) {
req->vhost = parsed_vhost->arg0();
}

if (req->schema.empty() || req->vhost.empty() || req->port == 0 || req->app.empty()) {
return srs_error_new(ERROR_RTMP_REQ_TCURL, "discovery tcUrl failed, tcUrl=%s, schema=%s, vhost=%s, port=%d, app=%s",
req->tcUrl.c_str(), req->schema.c_str(), req->vhost.c_str(), req->port, req->app.c_str());
}

// check vhost, allow default vhost.
if ((err = check_vhost(true)) != srs_success) {
return srs_error_wrap(err, "check vhost");
}

srs_trace("connected stream, tcUrl=%s, pageUrl=%s, swfUrl=%s, schema=%s, vhost=%s, port=%d, app=%s, stream=%s, args=%s",
req->tcUrl.c_str(), req->pageUrl.c_str(), req->swfUrl.c_str(),
req->schema.c_str(), req->vhost.c_str(), req->port,
req->app.c_str(), req->stream.c_str(), (req->args? "(obj)":"null"));

// do token traverse before serve it.
// @see https://github.com/ossrs/srs/pull/239
if (true) {
Expand All @@ -505,7 +505,7 @@ srs_error_t SrsRtmpConn::stream_service_cycle()
}
}
}

// security check
if ((err = security->check(info->type, ip, req)) != srs_success) {
return srs_error_wrap(err, "rtmp: security check");
Expand Down
2 changes: 1 addition & 1 deletion trunk/src/app/srs_app_rtsp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -643,7 +643,7 @@ srs_error_t SrsRtspConn::connect()
std::string schema, host, vhost, app, param;
int port;
srs_discovery_tc_url(rtsp_tcUrl, schema, host, vhost, app, rtsp_stream, port, param);

// generate output by template.
std::string output = output_template;
output = srs_string_replace(output, "[app]", app);
Expand Down
2 changes: 1 addition & 1 deletion trunk/src/libs/srs_librtmp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,7 @@ int srs_librtmp_context_parse_uri(Context* context)
int ret = ERROR_SUCCESS;

std::string schema;

srs_parse_rtmp_url(context->url, context->tcUrl, context->stream);

// when connect, we only need to parse the tcUrl
Expand Down

0 comments on commit 459272b

Please sign in to comment.