Report total, not latest-minute, message count in aircraft.json so that

the webmap value doesn't jump around over a reset.
This commit is contained in:
Oliver Jowett 2015-01-23 17:40:03 +00:00
parent c5b61a33fd
commit 245bbd8b97

View file

@ -756,7 +756,8 @@ char *generateAircraftJson(const char *url_path, int *len) {
"{ \"now\" : %d,\n"
" \"messages\" : %u,\n"
" \"aircraft\" : [",
(int)now, Modes.stats_current.messages_total);
(int)now,
Modes.stats_current.messages_total + Modes.stats_alltime.messages_total);
for (a = Modes.aircrafts; a; a = a->next) {
if (a->modeACflags & MODEAC_MSG_FLAG) { // skip any fudged ICAO records Mode A/C