diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 05e8306..91bc1a9 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -8,7 +8,7 @@ variables: before_script: - - dnf update -y --nogpgcheck && dnf install -y --nogpgcheck $DEPENDENCIES + - dnf update -y --nogpgcheck && dnf install -y --nogpgcheck $DEPENDENCIES && rpm -Uvh --oldpackage https://kojipkgs.fedoraproject.org//packages/meson/0.46.1/2.fc29/noarch/meson-0.46.1-2.fc29.noarch.rpm build: diff --git a/libfprint/drivers_api.h b/libfprint/drivers_api.h index 2bf547a..2679c77 100644 --- a/libfprint/drivers_api.h +++ b/libfprint/drivers_api.h @@ -40,10 +40,16 @@ #define fp_dbg g_debug #define fp_info g_debug #define fp_warn g_warning -#define fp_err g_error +#define fp_err g_warning -#define BUG_ON(condition) g_assert(!(condition)) -#define BUG() g_assert_not_reached() +#define BUG_ON(condition) G_STMT_START \ + if (condition) { \ + char *s; \ + s = g_strconcat ("BUG: (", #condition, ")", NULL); \ + g_warning ("%s: %s() %s:%d", s, G_STRFUNC, __FILE__, __LINE__); \ + g_free (s); \ + } G_STMT_END +#define BUG() BUG_ON(1) enum fp_dev_state { DEV_STATE_INITIAL = 0, diff --git a/libfprint/fp_internal.h b/libfprint/fp_internal.h index 3611f76..e750182 100644 --- a/libfprint/fp_internal.h +++ b/libfprint/fp_internal.h @@ -42,7 +42,7 @@ #define fp_dbg g_debug #define fp_info g_debug #define fp_warn g_warning -#define fp_err g_error +#define fp_err g_warning #define BUG_ON(condition) G_STMT_START \ if (condition) { \