Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of mbed-src by
Diff: common/us_ticker_api.c
- Revision:
- 361:56c2a6244bba
- Parent:
- 304:89b9c3a9a045
- Child:
- 388:fc1c6dc472ca
--- a/common/us_ticker_api.c Mon Oct 20 09:15:07 2014 +0100 +++ b/common/us_ticker_api.c Tue Oct 21 08:15:06 2014 +0100 @@ -37,7 +37,7 @@ return; } - if ((int)(head->timestamp - us_ticker_read()) <= 0) { + if ((int64_t)(head->timestamp - us_ticker_read()) <= 0) { // This event was in the past: // point to the following one and execute its handler ticker_event_t *p = head; @@ -70,7 +70,7 @@ ticker_event_t *prev = NULL, *p = head; while (p != NULL) { /* check if we come before p */ - if ((int)(timestamp - p->timestamp) <= 0) { + if ((int64_t)(timestamp - p->timestamp) < 0) { break; } /* go to the next element */