mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
Fix build warnings.
This commit is contained in:
parent
f44b694a17
commit
f9e8065b51
3 changed files with 4 additions and 5 deletions
|
@ -49,7 +49,7 @@ public:
|
|||
{
|
||||
static char buf[4096] = {0};
|
||||
int nbytes = vsnprintf(buf, sizeof(buf), fmt, vl);
|
||||
if (nbytes > 0 && nbytes < sizeof(buf)) {
|
||||
if (nbytes > 0 && nbytes < (int)sizeof(buf)) {
|
||||
// Srs log is always start with new line, replcae '\n' to '\0', make log easy to read.
|
||||
if (buf[nbytes - 1] == '\n') {
|
||||
buf[nbytes - 1] = '\0';
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue