mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-28 16:01:10 +02:00
change time_monotonic_ms() from time_t to int64_t
time_monotonic_ms values did wrap every ~24 days, leading to problems
in code that did not cope with that. Instead of fixing all places where
relative comparisons with time_monotonic_ms() are made, just use a
bigger datatype. Convert all users to the new type.
Origin commit data
------------------
Branch: ni/coolstream
Commit: 99ff4857ff
Author: Stefan Seyfried <seife@tuxbox-git.slipkontur.de>
Date: 2017-09-23 (Sat, 23 Sep 2017)
------------------
This commit was generated by Migit
This commit is contained in:
@@ -486,12 +486,12 @@ void *insertEventsfromFile(void * data)
|
||||
std::string epg_dir = (char *) data;
|
||||
indexname = epg_dir + "index.xml";
|
||||
|
||||
time_t now = time_monotonic_ms();
|
||||
int64_t now = time_monotonic_ms();
|
||||
xmlDocPtr index_parser = parseXmlFile(indexname.c_str());
|
||||
|
||||
if (index_parser == NULL) {
|
||||
readEventsFromDir(epg_dir, ev_count);
|
||||
printf("[sectionsd] Reading Information finished after %ld milliseconds (%d events)\n",
|
||||
printf("[sectionsd] Reading Information finished after %" PRId64 " milliseconds (%d events)\n",
|
||||
time_monotonic_ms()-now, ev_count);
|
||||
reader_ready = true;
|
||||
pthread_exit(NULL);
|
||||
@@ -515,7 +515,7 @@ void *insertEventsfromFile(void * data)
|
||||
|
||||
xmlFreeDoc(index_parser);
|
||||
printdate_ms(stdout);
|
||||
printf("[sectionsd] Reading Information finished after %ld milliseconds (%d events)\n",
|
||||
printf("[sectionsd] Reading Information finished after %" PRId64 " milliseconds (%d events)\n",
|
||||
time_monotonic_ms()-now, ev_count);
|
||||
|
||||
reader_ready = true;
|
||||
|
Reference in New Issue
Block a user