mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
refine code
This commit is contained in:
parent
60775485c4
commit
e5461d2df9
8 changed files with 13 additions and 9 deletions
|
@ -43,10 +43,13 @@ SrsThreadContext::~SrsThreadContext()
|
|||
{
|
||||
}
|
||||
|
||||
void SrsThreadContext::generate_id()
|
||||
int SrsThreadContext::generate_id()
|
||||
{
|
||||
static int id = 100;
|
||||
cache[st_thread_self()] = id++;
|
||||
|
||||
int gid = id++;
|
||||
cache[st_thread_self()] = gid;
|
||||
return gid;
|
||||
}
|
||||
|
||||
int SrsThreadContext::get_id()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue