Skip to content

Commit

Permalink
equeue: Fixed overflow in rtos-less timeout code
Browse files Browse the repository at this point in the history
Thanks to simonnilsson
  • Loading branch information
geky committed Aug 4, 2019
1 parent db4a347 commit 2bd4aad
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion equeue_mbed.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ bool equeue_sema_wait(equeue_sema_t *s, int ms) {
if (ms == 0) {
return false;
} else if (ms > 0) {
timeout.attach_us(callback(equeue_sema_timeout, s), ms*1000);
timeout.attach_us(callback(equeue_sema_timeout, s), (us_timestamp_t)ms*1000);
}

core_util_critical_section_enter();
Expand Down

0 comments on commit 2bd4aad

Please sign in to comment.