ACK: [PATCH] lib: don't use #pragma GCC push and pop
Alex Hung
alex.hung at canonical.com
Wed Aug 20 16:03:26 UTC 2014
On 08/20/2014 04:24 PM, Colin King wrote:
> From: Colin Ian King <colin.king at canonical.com>
>
> Older versions of GCC don't support push and pop pragmas (for example
> on Lucid builds with gcc 4.4.x), so instead just re-instate the error
> state for a pariticular warning.
>
> Signed-off-by: Colin Ian King <colin.king at canonical.com>
> ---
> src/lib/include/fwts_acpi_object_eval.h | 3 +--
> src/lib/src/fwts_acpi_object_eval.c | 3 +--
> 2 files changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/src/lib/include/fwts_acpi_object_eval.h b/src/lib/include/fwts_acpi_object_eval.h
> index 255bc0c..60cbf6f 100644
> --- a/src/lib/include/fwts_acpi_object_eval.h
> +++ b/src/lib/include/fwts_acpi_object_eval.h
> @@ -23,10 +23,9 @@
> #include "fwts.h"
>
> /* acpica headers */
> -#pragma GCC diagnostic push
> #pragma GCC diagnostic ignored "-Wunused-parameter"
> #include "acpi.h"
> -#pragma GCC diagnostic pop
> +#pragma GCC diagnostic error "-Wunused-parameter"
>
> int fwts_acpi_init(fwts_framework *fw);
> int fwts_acpi_deinit(fwts_framework *fw);
> diff --git a/src/lib/src/fwts_acpi_object_eval.c b/src/lib/src/fwts_acpi_object_eval.c
> index 5cc19a3..fdfb4dd 100644
> --- a/src/lib/src/fwts_acpi_object_eval.c
> +++ b/src/lib/src/fwts_acpi_object_eval.c
> @@ -24,10 +24,9 @@
> #include <unistd.h>
>
> /* acpica headers */
> -#pragma GCC diagnostic push
> #pragma GCC diagnostic ignored "-Wunused-parameter"
> #include "acpi.h"
> -#pragma GCC diagnostic pop
> +#pragma GCC diagnostic error "-Wunused-parameter"
> #include "fwts_acpi_object_eval.h"
>
> typedef struct {
>
Acked-by: Alex Hung <alex.hung at canonical.com>
--
Cheers,
Alex Hung
More information about the fwts-devel
mailing list