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

replace the TAB with 4spaces

This commit is contained in:
winlin 2015-01-05 12:14:02 +08:00
parent 344ff24f66
commit 4bb17f0c81
3 changed files with 168 additions and 168 deletions

View file

@ -27,13 +27,13 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
SrsStreamInfo::SrsStreamInfo()
{
_req = NULL;
_req = NULL;
}
SrsStreamInfo::~SrsStreamInfo()
{
if (_req != NULL)
delete _req;
if (_req != NULL)
delete _req;
}
SrsStatistic *SrsStatistic::_instance = NULL;
@ -45,31 +45,31 @@ SrsStatistic::SrsStatistic()
SrsStatistic::~SrsStatistic()
{
SrsStreamInfoMap::iterator it;
for (it = pool.begin(); it != pool.end(); it++) {
delete it->second;
}
SrsStreamInfoMap::iterator it;
for (it = pool.begin(); it != pool.end(); it++) {
delete it->second;
}
}
SrsStreamInfoMap* SrsStatistic::get_pool()
{
return &pool;
return &pool;
}
SrsStreamInfo* SrsStatistic::get(void *p)
{
SrsStreamInfoMap::iterator it = pool.find(p);
if (it == pool.end()) {
pool[p] = new SrsStreamInfo();
return pool[p];
} else {
return it->second;
}
SrsStreamInfoMap::iterator it = pool.find(p);
if (it == pool.end()) {
pool[p] = new SrsStreamInfo();
return pool[p];
} else {
return it->second;
}
}
void SrsStatistic::add_request_info(void *p, SrsRequest *req)
{
SrsStreamInfo *info = get(p);
if (info->_req == NULL)
info->_req = req->copy();
SrsStreamInfo *info = get(p);
if (info->_req == NULL)
info->_req = req->copy();
}