Browse Source

MT#55283 safeguard auto cleanup function

Change-Id: I4aa6f604a74cb5f6467745bdea214954227dc0eb
pull/1918/head
Richard Fuchs 9 months ago
parent
commit
fc3ce1f81d
1 changed files with 2 additions and 1 deletions
  1. +2
    -1
      lib/containers.h

+ 2
- 1
lib/containers.h View File

@ -440,7 +440,8 @@ static inline void g_queue_clear_full(GQueue *q, GDestroyNotify free_func) {
return type_name##_new_sized(0); \
} \
static inline void type_name##_destroy_ptr(type_name *A) { \
g_ptr_array_free(&(A)->a, TRUE); \
if (A) \
g_ptr_array_free(&(A)->a, TRUE); \
} \
G_DEFINE_AUTOPTR_CLEANUP_FUNC(type_name, type_name##_destroy_ptr)


Loading…
Cancel
Save