正在显示
1 个修改的文件
包含
2 行增加
和
4 行删除
@@ -147,7 +147,7 @@ SrsProcSelfStat::SrsProcSelfStat() | @@ -147,7 +147,7 @@ SrsProcSelfStat::SrsProcSelfStat() | ||
147 | 147 | ||
148 | pid = 0; | 148 | pid = 0; |
149 | memset(comm, 0, sizeof(comm)); | 149 | memset(comm, 0, sizeof(comm)); |
150 | - state = 0; | 150 | + state = '0'; |
151 | ppid = 0; | 151 | ppid = 0; |
152 | pgrp = 0; | 152 | pgrp = 0; |
153 | session = 0; | 153 | session = 0; |
@@ -1146,7 +1146,6 @@ void srs_api_dump_summaries(std::stringstream& ss) | @@ -1146,7 +1146,6 @@ void srs_api_dump_summaries(std::stringstream& ss) | ||
1146 | int64_t now = srs_get_system_time_ms(); | 1146 | int64_t now = srs_get_system_time_ms(); |
1147 | double srs_uptime = (now - p->srs_startup_time) / 100 / 10.0; | 1147 | double srs_uptime = (now - p->srs_startup_time) / 100 / 10.0; |
1148 | 1148 | ||
1149 | - bool n_ok = false; | ||
1150 | int64_t n_sample_time = 0; | 1149 | int64_t n_sample_time = 0; |
1151 | int64_t nr_bytes = 0; | 1150 | int64_t nr_bytes = 0; |
1152 | int64_t ns_bytes = 0; | 1151 | int64_t ns_bytes = 0; |
@@ -1160,7 +1159,6 @@ void srs_api_dump_summaries(std::stringstream& ss) | @@ -1160,7 +1159,6 @@ void srs_api_dump_summaries(std::stringstream& ss) | ||
1160 | continue; | 1159 | continue; |
1161 | } | 1160 | } |
1162 | 1161 | ||
1163 | - n_ok = true; | ||
1164 | nr_bytes += o.rbytes; | 1162 | nr_bytes += o.rbytes; |
1165 | ns_bytes += o.sbytes; | 1163 | ns_bytes += o.sbytes; |
1166 | n_sample_time = o.sample_time; | 1164 | n_sample_time = o.sample_time; |
@@ -1168,7 +1166,7 @@ void srs_api_dump_summaries(std::stringstream& ss) | @@ -1168,7 +1166,7 @@ void srs_api_dump_summaries(std::stringstream& ss) | ||
1168 | 1166 | ||
1169 | // all data is ok? | 1167 | // all data is ok? |
1170 | bool ok = (r->ok && u->ok && s->ok && c->ok | 1168 | bool ok = (r->ok && u->ok && s->ok && c->ok |
1171 | - && d->ok && m->ok && p->ok && n_ok && nrs->ok); | 1169 | + && d->ok && m->ok && p->ok && nrs->ok); |
1172 | 1170 | ||
1173 | ss << SRS_JOBJECT_START | 1171 | ss << SRS_JOBJECT_START |
1174 | << SRS_JFIELD_ERROR(ERROR_SUCCESS) << SRS_JFIELD_CONT | 1172 | << SRS_JFIELD_ERROR(ERROR_SUCCESS) << SRS_JFIELD_CONT |
-
请 注册 或 登录 后发表评论