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

refine srs-librtmp log macro

This commit is contained in:
winlin 2014-11-08 13:41:47 +08:00
parent f92303c764
commit 6de83db76e
4 changed files with 21 additions and 18 deletions

View file

@ -234,14 +234,11 @@ extern int srs_version_revision();
extern int64_t srs_get_time_ms();
extern int64_t srs_get_nsend_bytes(srs_rtmp_t rtmp);
extern int64_t srs_get_nrecv_bytes(srs_rtmp_t rtmp);
// log to console.
// log to console, for use srs-librtmp application.
extern const char* srs_format_time();
#ifndef srs_trace
#define srs_trace(msg, ...) printf("[%s]", srs_format_time());printf(msg, ##__VA_ARGS__);printf("\n")
#endif
#ifndef srs_verbose
#define srs_verbose(msg, ...) printf("[%s]", srs_format_time());printf(msg, ##__VA_ARGS__);printf("\n")
#endif
#define srs_trace(msg, ...) printf("[%s]", srs_format_time());printf(msg, ##__VA_ARGS__);printf("\n")
#define srs_verbose(msg, ...) printf("[%s]", srs_format_time());printf(msg, ##__VA_ARGS__);printf("\n")
/*************************************************************
**************************************************************