Re: [spice-common v2 1/3] log: Remove SPICE_DISABLE_ABORT

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



ACK series

On Tue, 2018-07-03 at 12:42 +0200, Christophe Fergeau wrote:
> spice-gtk was the last user, and stopped using it on Jun 14th 2017
> in 040090ccba34 "build-sys: remove -DSPICE_DISABLE_ABORT"
> 
> Signed-off-by: Christophe Fergeau <cfergeau@xxxxxxxxxx>
> ---
>  common/log.c          |  4 ----
>  common/spice_common.h |  4 ----
>  tests/test-logging.c  | 14 ++------------
>  3 files changed, 2 insertions(+), 20 deletions(-)
> 
> diff --git a/common/log.c b/common/log.c
> index 7e460f0..b59c8a8 100644
> --- a/common/log.c
> +++ b/common/log.c
> @@ -34,12 +34,8 @@ static int glib_debug_level = INT_MAX;
>  static int abort_mask = 0;
>  
>  #ifndef SPICE_ABORT_MASK_DEFAULT
> -#ifdef SPICE_DISABLE_ABORT
> -#define SPICE_ABORT_MASK_DEFAULT 0
> -#else
>  #define SPICE_ABORT_MASK_DEFAULT
> (G_LOG_LEVEL_CRITICAL|G_LOG_LEVEL_ERROR)
>  #endif
> -#endif
>  
>  #define G_LOG_DOMAIN "Spice"
>  
> diff --git a/common/spice_common.h b/common/spice_common.h
> index 5572326..f9a7b3b 100644
> --- a/common/spice_common.h
> +++ b/common/spice_common.h
> @@ -28,10 +28,6 @@
>  #include "backtrace.h"
>  #include "log.h"
>  
> -#ifdef SPICE_DISABLE_ABORT
> -#define spice_abort() do { } while(0)
> -#else
>  #define spice_abort() abort()
> -#endif
>  
>  #endif
> diff --git a/tests/test-logging.c b/tests/test-logging.c
> index 437e0a1..559d656 100644
> --- a/tests/test-logging.c
> +++ b/tests/test-logging.c
> @@ -89,8 +89,7 @@ static void test_spice_fatal_warning(void)
>      g_unsetenv("G_DEBUG");
>  }
>  
> -/* Checks that spice_critical() aborts by default if
> SPICE_DISABLE_ABORT is not
> - * defined at compile-time */
> +/* Checks that spice_critical() aborts by default */
>  static void test_spice_fatal_critical(void)
>  {
>      if (g_test_subprocess()) {
> @@ -98,11 +97,7 @@ static void test_spice_fatal_critical(void)
>          return;
>      }
>      g_test_trap_subprocess(NULL, 0, 0);
> -#ifdef SPICE_DISABLE_ABORT
> -    g_test_trap_assert_passed();
> -#else
>      g_test_trap_assert_failed();
> -#endif
>      g_test_trap_assert_stderr("*spice_critical*");
>  }
>  
> @@ -132,8 +127,7 @@ static void test_spice_fatal_g_critical(void)
>      g_unsetenv("G_DEBUG");
>  }
>  
> -/* Checks that spice_return_if_fail() aborts by default unless
> - * SPICE_DISABLE_ABORT was defined at compile time*/
> +/* Checks that spice_return_if_fail() aborts by default */
>  static void test_spice_fatal_return_if_fail(void)
>  {
>      if (g_test_subprocess()) {
> @@ -141,11 +135,7 @@ static void
> test_spice_fatal_return_if_fail(void)
>          return;
>      }
>      g_test_trap_subprocess(NULL, 0, 0);
> -#ifdef SPICE_DISABLE_ABORT
> -    g_test_trap_assert_passed();
> -#else
>      g_test_trap_assert_failed();
> -#endif
>      g_test_trap_assert_stderr("*test_spice_fatal_return_if_fail*");
>  }
>  
_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/spice-devel




[Index of Archives]     [Linux Virtualization]     [Linux Virtualization]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]