mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
Refine init of global variables
This commit is contained in:
parent
e8f7c913b0
commit
b6f2745822
2 changed files with 4 additions and 2 deletions
|
@ -63,9 +63,10 @@ public:
|
||||||
public:
|
public:
|
||||||
SrsPps();
|
SrsPps();
|
||||||
virtual ~SrsPps();
|
virtual ~SrsPps();
|
||||||
public:
|
private:
|
||||||
// Setup the clock, use global clock if not set.
|
// Setup the clock, use global clock if not set.
|
||||||
void set_clock(SrsWallClock* clk);
|
void set_clock(SrsWallClock* clk);
|
||||||
|
public:
|
||||||
// Update with the nn which is target.
|
// Update with the nn which is target.
|
||||||
void update();
|
void update();
|
||||||
// Update with the nn.
|
// Update with the nn.
|
||||||
|
|
|
@ -29,6 +29,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
#include <srs_app_config.hpp>
|
#include <srs_app_config.hpp>
|
||||||
#include <srs_app_log.hpp>
|
#include <srs_app_log.hpp>
|
||||||
#include <srs_app_rtc_dtls.hpp>
|
#include <srs_app_rtc_dtls.hpp>
|
||||||
|
#include <srs_app_threads.hpp>
|
||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
@ -54,7 +55,7 @@ bool _srs_in_docker = false;
|
||||||
srs_error_t prepare_main() {
|
srs_error_t prepare_main() {
|
||||||
srs_error_t err = srs_success;
|
srs_error_t err = srs_success;
|
||||||
|
|
||||||
if ((err = srs_st_init()) != srs_success) {
|
if ((err = srs_thread_initialize()) != srs_success) {
|
||||||
return srs_error_wrap(err, "init st");
|
return srs_error_wrap(err, "init st");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue