mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
Refine get_pithy_print in time unit
This commit is contained in:
parent
60f9561d2d
commit
5df8f2f6c1
6 changed files with 22 additions and 13 deletions
|
@ -4055,16 +4055,16 @@ string SrsConfig::get_pid_file()
|
|||
return conf->arg0();
|
||||
}
|
||||
|
||||
int SrsConfig::get_pithy_print_ms()
|
||||
srs_utime_t SrsConfig::get_pithy_print()
|
||||
{
|
||||
static int DEFAULT = 10000;
|
||||
static srs_utime_t DEFAULT = 10 * SRS_UTIME_SECONDS;
|
||||
|
||||
SrsConfDirective* conf = root->get("pithy_print_ms");
|
||||
if (!conf || conf->arg0().empty()) {
|
||||
return DEFAULT;
|
||||
}
|
||||
|
||||
return ::atoi(conf->arg0().c_str());
|
||||
return (srs_utime_t)(::atoi(conf->arg0().c_str()) * SRS_UTIME_MILLISECONDS);
|
||||
}
|
||||
|
||||
bool SrsConfig::get_utc_time()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue