diff --git a/src/libnm-std-aux/nm-std-aux.h b/src/libnm-std-aux/nm-std-aux.h index a5e5abd3d5..71f1881fee 100644 --- a/src/libnm-std-aux/nm-std-aux.h +++ b/src/libnm-std-aux/nm-std-aux.h @@ -235,6 +235,8 @@ typedef uint64_t _nm_bitwise nm_be64_t; #define nm_assert(cond) \ ({ \ + NM_PRAGMA_WARNING_DISABLE("-Wnonnull-compare"); \ + \ /* nm_assert() must do *nothing* of effect, except evaluating * @cond (0 or 1 times). * @@ -252,6 +254,9 @@ typedef uint64_t _nm_bitwise nm_be64_t; } else { \ _nm_assert_fail(#cond); \ } \ + \ + NM_PRAGMA_WARNING_REENABLE; \ + \ 1; \ })