[lttng-dev] [PATCH lttng-tools] Fix: do not print error and bug messages when quiet (-q) is present

Jérémie Galarneau jeremie.galarneau at efficios.com
Thu Jan 14 11:58:56 EST 2016


Merged, thanks!

Jérémie

On Mon, Jan 11, 2016 at 5:32 PM, Jonathan Rajotte
<jonathan.rajotte-julien at efficios.com> wrote:
> Conform to the lttng man page
>
> fixes #988
>
> Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien at efficios.com>
> ---
>  src/common/error.h | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/src/common/error.h b/src/common/error.h
> index e0cb158..d072b00 100644
> --- a/src/common/error.h
> +++ b/src/common/error.h
> @@ -85,9 +85,8 @@ extern int lttng_opt_mi;
>                                 ((type & (PRINT_DBG | PRINT_DBG2 | PRINT_DBG3)) &&  \
>                                         lttng_opt_verbose == 3))) {                     \
>                         fprintf(stderr, fmt, ## args);                          \
> -               } else if (lttng_opt_quiet == 0 && (type & (PRINT_WARN))) { \
> -                       fprintf(stderr, fmt, ## args);                          \
> -               } else if (type & (PRINT_ERR | PRINT_BUG)) {                \
> +               } else if (lttng_opt_quiet == 0 &&                          \
> +                               (type & (PRINT_WARN | PRINT_ERR | PRINT_BUG))) {    \
>                         fprintf(stderr, fmt, ## args);                          \
>                 }                                                           \
>         } while (0);
> --
> 2.5.0
>



-- 
Jérémie Galarneau
EfficiOS Inc.
http://www.efficios.com



More information about the lttng-dev mailing list