mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-09-01 01:41:23 +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.
This commit is contained in:
committed by
Jacek Jendrzej
parent
c7f429019d
commit
8dad062eff
@@ -133,14 +133,14 @@ void CShellWindow::exec()
|
||||
fds.events = POLLIN | POLLHUP | POLLERR;
|
||||
fcntl(fds.fd, F_SETFL, fcntl(fds.fd, F_GETFL, 0) | O_NONBLOCK);
|
||||
|
||||
time_t lastPaint = time_monotonic_ms();
|
||||
int64_t lastPaint = time_monotonic_ms();
|
||||
bool ok = true, nlseen = false, dirty = false, incomplete = false;
|
||||
char output[1024];
|
||||
std::string txt = "";
|
||||
std::string line = "";
|
||||
|
||||
do {
|
||||
time_t now;
|
||||
int64_t now;
|
||||
fds.revents = 0;
|
||||
int r = poll(&fds, 1, 300);
|
||||
if (r > 0) {
|
||||
|
Reference in New Issue
Block a user