shared: avoid extra asserts in production code for NMRefString

These asserts were always intended as for extra debugging mode.
Don't enable them in production code.

Fixes: 908fadec96 ('shared: add NMRefString')
This commit is contained in:
Thomas Haller
2019-10-16 08:48:37 +02:00
parent 61ccdf1710
commit 5ed917a8c1

View File

@@ -50,6 +50,7 @@ _ref_string_equal (gconstpointer pa, gconstpointer pb)
static void
_ASSERT (const RefString *rstr0)
{
#if NM_MORE_ASSERTS
int r;
nm_assert (rstr0);
@@ -62,6 +63,7 @@ _ASSERT (const RefString *rstr0)
nm_assert (rstr0 == g_hash_table_lookup (gl_hash, rstr0));
G_UNLOCK (gl_lock);
#endif
}
/**