winlin

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

@@ -84,9 +84,8 @@ void SrsHttpHeartbeat::heartbeat() @@ -84,9 +84,8 @@ void SrsHttpHeartbeat::heartbeat()
84 84
85 ISrsHttpMessage* msg = NULL; 85 ISrsHttpMessage* msg = NULL;
86 if ((ret = http.post(uri.get_path(), req, &msg)) != ERROR_SUCCESS) { 86 if ((ret = http.post(uri.get_path(), req, &msg)) != ERROR_SUCCESS) {
87 - srs_info("http post hartbeart uri failed. "  
88 - "url=%s, request=%s, response=%s, ret=%d",  
89 - url.c_str(), req.c_str(), res.c_str(), ret); 87 + srs_info("http post hartbeart uri failed. url=%s, request=%s, ret=%d",
  88 + url.c_str(), req.c_str(), ret);
90 return; 89 return;
91 } 90 }
92 SrsAutoFree(ISrsHttpMessage, msg); 91 SrsAutoFree(ISrsHttpMessage, msg);
@@ -96,9 +95,8 @@ void SrsHttpHeartbeat::heartbeat() @@ -96,9 +95,8 @@ void SrsHttpHeartbeat::heartbeat()
96 return; 95 return;
97 } 96 }
98 97
99 - srs_info("http hook hartbeart success. "  
100 - "url=%s, request=%s, status_code=%d, response=%s, ret=%d",  
101 - url.c_str(), req.c_str(), status_code, res.c_str(), ret); 98 + srs_info("http hook hartbeart success. url=%s, request=%s, response=%s, ret=%d",
  99 + url.c_str(), req.c_str(), res.c_str(), ret);
102 100
103 return; 101 return;
104 } 102 }
@@ -187,7 +187,7 @@ int SrsHttpClient::connect() @@ -187,7 +187,7 @@ int SrsHttpClient::connect()
187 host.c_str(), port, timeout_us, ret); 187 host.c_str(), port, timeout_us, ret);
188 return ret; 188 return ret;
189 } 189 }
190 - srs_info("connect to server success. server=%s, port=%d", host, port); 190 + srs_info("connect to server success. server=%s, port=%d", host.c_str(), port);
191 191
192 srs_assert(!skt); 192 srs_assert(!skt);
193 skt = new SrsStSocket(stfd); 193 skt = new SrsStSocket(stfd);
@@ -134,7 +134,7 @@ int SrsStreamCache::cycle() @@ -134,7 +134,7 @@ int SrsStreamCache::cycle()
134 } 134 }
135 135
136 if (count <= 0) { 136 if (count <= 0) {
137 - srs_info("http: mw sleep %dms for no msg", mw_sleep); 137 + srs_info("http: sleep %dms for no msg", SRS_CONSTS_RTMP_PULSE_TIMEOUT_US);
138 // directly use sleep, donot use consumer wait. 138 // directly use sleep, donot use consumer wait.
139 st_usleep(SRS_CONSTS_RTMP_PULSE_TIMEOUT_US); 139 st_usleep(SRS_CONSTS_RTMP_PULSE_TIMEOUT_US);
140 140
@@ -522,7 +522,7 @@ int SrsLiveStream::serve_http(ISrsHttpResponseWriter* w, ISrsHttpMessage* r) @@ -522,7 +522,7 @@ int SrsLiveStream::serve_http(ISrsHttpResponseWriter* w, ISrsHttpMessage* r)
522 } 522 }
523 523
524 if (count <= 0) { 524 if (count <= 0) {
525 - srs_info("http: mw sleep %dms for no msg", mw_sleep); 525 + srs_info("http: sleep %dms for no msg", SRS_CONSTS_RTMP_PULSE_TIMEOUT_US);
526 // directly use sleep, donot use consumer wait. 526 // directly use sleep, donot use consumer wait.
527 st_usleep(SRS_CONSTS_RTMP_PULSE_TIMEOUT_US); 527 st_usleep(SRS_CONSTS_RTMP_PULSE_TIMEOUT_US);
528 528