1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

fix #132: build failed when enable the info or verbose log.

This commit is contained in:
winlin 2015-07-10 11:50:35 +08:00
parent 2567a89599
commit 0aa053433c
3 changed files with 7 additions and 9 deletions

View file

@ -84,9 +84,8 @@ void SrsHttpHeartbeat::heartbeat()
ISrsHttpMessage* msg = NULL; ISrsHttpMessage* msg = NULL;
if ((ret = http.post(uri.get_path(), req, &msg)) != ERROR_SUCCESS) { if ((ret = http.post(uri.get_path(), req, &msg)) != ERROR_SUCCESS) {
srs_info("http post hartbeart uri failed. " srs_info("http post hartbeart uri failed. url=%s, request=%s, ret=%d",
"url=%s, request=%s, response=%s, ret=%d", url.c_str(), req.c_str(), ret);
url.c_str(), req.c_str(), res.c_str(), ret);
return; return;
} }
SrsAutoFree(ISrsHttpMessage, msg); SrsAutoFree(ISrsHttpMessage, msg);
@ -96,9 +95,8 @@ void SrsHttpHeartbeat::heartbeat()
return; return;
} }
srs_info("http hook hartbeart success. " srs_info("http hook hartbeart success. url=%s, request=%s, response=%s, ret=%d",
"url=%s, request=%s, status_code=%d, response=%s, ret=%d", url.c_str(), req.c_str(), res.c_str(), ret);
url.c_str(), req.c_str(), status_code, res.c_str(), ret);
return; return;
} }

View file

@ -187,7 +187,7 @@ int SrsHttpClient::connect()
host.c_str(), port, timeout_us, ret); host.c_str(), port, timeout_us, ret);
return ret; return ret;
} }
srs_info("connect to server success. server=%s, port=%d", host, port); srs_info("connect to server success. server=%s, port=%d", host.c_str(), port);
srs_assert(!skt); srs_assert(!skt);
skt = new SrsStSocket(stfd); skt = new SrsStSocket(stfd);

View file

@ -134,7 +134,7 @@ int SrsStreamCache::cycle()
} }
if (count <= 0) { if (count <= 0) {
srs_info("http: mw sleep %dms for no msg", mw_sleep); srs_info("http: sleep %dms for no msg", SRS_CONSTS_RTMP_PULSE_TIMEOUT_US);
// directly use sleep, donot use consumer wait. // directly use sleep, donot use consumer wait.
st_usleep(SRS_CONSTS_RTMP_PULSE_TIMEOUT_US); st_usleep(SRS_CONSTS_RTMP_PULSE_TIMEOUT_US);
@ -522,7 +522,7 @@ int SrsLiveStream::serve_http(ISrsHttpResponseWriter* w, ISrsHttpMessage* r)
} }
if (count <= 0) { if (count <= 0) {
srs_info("http: mw sleep %dms for no msg", mw_sleep); srs_info("http: sleep %dms for no msg", SRS_CONSTS_RTMP_PULSE_TIMEOUT_US);
// directly use sleep, donot use consumer wait. // directly use sleep, donot use consumer wait.
st_usleep(SRS_CONSTS_RTMP_PULSE_TIMEOUT_US); st_usleep(SRS_CONSTS_RTMP_PULSE_TIMEOUT_US);