From babf13d12ea839f0121490126a2d456af1744f0e Mon Sep 17 00:00:00 2001 From: Apple Date: Tue, 12 Aug 2014 18:11:46 +0000 Subject: [PATCH] libdispatch-339.92.1.tar.gz --- src/introspection.c | 2 +- src/trace.h | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/introspection.c b/src/introspection.c index d1dd04d..18c11df 100644 --- a/src/introspection.c +++ b/src/introspection.c @@ -252,7 +252,7 @@ _dispatch_introspection_source_get_info(dispatch_source_t ds) dispatch_function_t handler = dr->ds_handler_func; bool handler_is_block = ds->ds_handler_is_block; bool after = (handler == _dispatch_after_timer_callback); - if (after) { + if (after && !(ds->ds_atomic_flags & DSF_CANCELED)) { dispatch_continuation_t dc = ctxt; ctxt = dc->dc_ctxt; handler = dc->dc_func; diff --git a/src/trace.h b/src/trace.h index 9a0f152..d6b31fe 100644 --- a/src/trace.h +++ b/src/trace.h @@ -190,7 +190,8 @@ static inline dispatch_function_t _dispatch_trace_timer_function(dispatch_source_t ds, dispatch_source_refs_t dr) { dispatch_function_t func = dr->ds_handler_func; - if (func == _dispatch_after_timer_callback) { + if (func == _dispatch_after_timer_callback && + !(ds->ds_atomic_flags & DSF_CANCELED)) { dispatch_continuation_t dc = ds->do_ctxt; func = dc->dc_func != _dispatch_call_block_and_release ? dc->dc_func : dc->dc_ctxt ? _dispatch_Block_invoke(dc->dc_ctxt) : NULL; -- 2.45.2