summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2019-09-23 13:40:38 +0200
committerThomas Haller <thaller@redhat.com>2019-09-23 13:44:36 +0200
commit3214841765ccf7901549d2e36153a06e3b3a5822 (patch)
tree4fa6653d2ed6eba9501151c73bdc0b2ca2842600
parent4b1cb404fd545b748beeb440ff37afaf9cc497e1 (diff)
downloadNetworkManager-3214841765ccf7901549d2e36153a06e3b3a5822.tar.gz
shared/trivial: rename _nm_g_slice_free_fcn1() macro to nm_g_slice_free_fcn1()
The leading underscore has the notion that this would be a private function. It really isn't, and it would be fine for the user to call it directly. Just like we have g_slice_free() and g_slice_free1().
-rw-r--r--shared/nm-glib-aux/nm-shared-utils.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/shared/nm-glib-aux/nm-shared-utils.h b/shared/nm-glib-aux/nm-shared-utils.h
index 75b5d387c5..c2cf8fb4de 100644
--- a/shared/nm-glib-aux/nm-shared-utils.h
+++ b/shared/nm-glib-aux/nm-shared-utils.h
@@ -640,7 +640,7 @@ _nm_g_slice_free_fcn_define (12)
_nm_g_slice_free_fcn_define (16)
_nm_g_slice_free_fcn_define (32)
-#define _nm_g_slice_free_fcn1(mem_size) \
+#define nm_g_slice_free_fcn1(mem_size) \
({ \
void (*_fcn) (gpointer); \
\
@@ -677,9 +677,9 @@ _nm_g_slice_free_fcn_define (32)
* Returns: a function pointer with GDestroyNotify signature
* for g_slice_free(type,*).
*
- * Only certain types are implemented. You'll get an assertion
- * using the wrong type. */
-#define nm_g_slice_free_fcn(type) (_nm_g_slice_free_fcn1 (sizeof (type)))
+ * Only certain types are implemented. You'll get a compile time
+ * error for the wrong types. */
+#define nm_g_slice_free_fcn(type) (nm_g_slice_free_fcn1 (sizeof (type)))
#define nm_g_slice_free_fcn_gint64 (nm_g_slice_free_fcn (gint64))