From f0c75c75704f56ba239d63c05054836f90dacc55 Mon Sep 17 00:00:00 2001 From: Thomas Preud'homme Date: Wed, 1 Jun 2011 15:20:10 +0200 Subject: [PATCH] SINK thread (not INTERM) notify its termination Use !!node_param->type & SINK in likely macro to test wether we are a SINK node or an INTERM node. --- communication_techniques/src/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/communication_techniques/src/main.c b/communication_techniques/src/main.c index 911b70b..f4317d7 100644 --- a/communication_techniques/src/main.c +++ b/communication_techniques/src/main.c @@ -490,7 +490,7 @@ static int consumer_data(node_param_t *node_param) /*printf("[%p] Just received %d word-sized data%s\n", (void *) pthread_self(), WORDS_PER_LINE, WORDS_PER_LINE ? "s" : "");*/ } } - if (unlikely(!(node_param->type & SINK))) + if (unlikely(!!(node_param->type & SINK))) printf("[%p] Consumer finished !\n", (void*) pthread_self()); if (delayed_error) return -1;