[lttng-dev] [PATCH lttng-tools] Fix: double similar condition

Jérémie Galarneau jeremie.galarneau at efficios.com
Mon Mar 26 16:27:11 EDT 2018


Good catch! Merged in master and stable-2.10.

Thanks!
Jérémie

On Wed, Mar 14, 2018 at 05:35:05PM -0400, Jonathan Rajotte wrote:
> Based on the pattern of the function, threshold_bytes should be used
> inside the "else if" condition.
> 
> Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien at efficios.com>
> ---
>  src/bin/lttng-sessiond/notification-thread-events.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/bin/lttng-sessiond/notification-thread-events.c b/src/bin/lttng-sessiond/notification-thread-events.c
> index 39462b5..6d5e625 100644
> --- a/src/bin/lttng-sessiond/notification-thread-events.c
> +++ b/src/bin/lttng-sessiond/notification-thread-events.c
> @@ -295,7 +295,7 @@ unsigned long lttng_condition_buffer_usage_hash(
>  
>  		val = condition->threshold_ratio.value * (double) UINT32_MAX;
>  		hash ^= hash_key_u64(&val, lttng_ht_seed);
> -	} else if (condition->threshold_ratio.set) {
> +	} else if (condition->threshold_bytes.set) {
>  		uint64_t val;
>  
>  		val = condition->threshold_bytes.value;
> -- 
> 2.7.4
> 


More information about the lttng-dev mailing list