From ab17cc71dc1c601b8508b9b461f01a78ed48e8cf Mon Sep 17 00:00:00 2001 From: Rohit Grover Date: Wed, 27 Aug 2014 09:00:59 +0100 Subject: [PATCH] minor simplification of a reused expression --- libraries/mbed/common/us_ticker_api.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/mbed/common/us_ticker_api.c b/libraries/mbed/common/us_ticker_api.c index 749354a297..8218b9ccda 100644 --- a/libraries/mbed/common/us_ticker_api.c +++ b/libraries/mbed/common/us_ticker_api.c @@ -97,7 +97,7 @@ void us_ticker_remove_event(ticker_event_t *obj) { if (head == obj) { // first in the list, so just drop me head = obj->next; - if (obj->next == NULL) { + if (head == NULL) { us_ticker_disable_interrupt(); } else { us_ticker_set_interrupt(head->timestamp);