mirror of
				https://github.com/ossrs/srs.git
				synced 2025-03-09 15:49:59 +00:00 
			
		
		
		
	Refine resource manager, fix loop and context switching bug
This commit is contained in:
		
							parent
							
								
									033e2f9210
								
							
						
					
					
						commit
						1a33452e95
					
				
					 3 changed files with 93 additions and 2 deletions
				
			
		| 
						 | 
				
			
			@ -64,6 +64,7 @@ private:
 | 
			
		|||
    std::vector<ISrsDisposingHandler*> handlers_;
 | 
			
		||||
    // The zombie connections, we will delete it asynchronously.
 | 
			
		||||
    std::vector<ISrsResource*> zombies_;
 | 
			
		||||
    std::vector<ISrsResource*>* p_disposing_;
 | 
			
		||||
private:
 | 
			
		||||
    // The connections without any id.
 | 
			
		||||
    std::vector<ISrsResource*> conns_;
 | 
			
		||||
| 
						 | 
				
			
			@ -96,6 +97,7 @@ public:
 | 
			
		|||
    virtual void remove(ISrsResource* c);
 | 
			
		||||
private:
 | 
			
		||||
    void clear();
 | 
			
		||||
    void do_clear();
 | 
			
		||||
    void dispose(ISrsResource* c);
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue