You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by GitBox <gi...@apache.org> on 2019/01/10 14:06:17 UTC

[GitHub] yang325 closed pull request #256: porting: Check FreeRTOS timer status before stopping it

yang325 closed pull request #256: porting: Check FreeRTOS timer status before stopping it
URL: https://github.com/apache/mynewt-nimble/pull/256
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/porting/npl/freertos/include/nimble/nimble_npl_os.h b/porting/npl/freertos/include/nimble/nimble_npl_os.h
index 00f64ba2..2ef7524c 100644
--- a/porting/npl/freertos/include/nimble/nimble_npl_os.h
+++ b/porting/npl/freertos/include/nimble/nimble_npl_os.h
@@ -206,7 +206,9 @@ ble_npl_callout_reset(struct ble_npl_callout *co, ble_npl_time_t ticks)
 static inline void
 ble_npl_callout_stop(struct ble_npl_callout *co)
 {
-    xTimerStop(co->handle, portMAX_DELAY);
+    if (co->handle) {
+        xTimerStop(co->handle, portMAX_DELAY);
+    }
 }
 
 static inline bool


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services