Skip to content
Snippets Groups Projects
Commit 4cacbcd0 authored by Andreas Gattringer's avatar Andreas Gattringer
Browse files

additional sanity check in free_string_array

parent 81105b83
No related branches found
No related tags found
No related merge requests found
...@@ -160,7 +160,7 @@ struct string_array *copy_string_array(const struct string_array *src) ...@@ -160,7 +160,7 @@ struct string_array *copy_string_array(const struct string_array *src)
void free_string_array(struct string_array **array) void free_string_array(struct string_array **array)
{ {
if (array == NULL) return; if (array == NULL || *array == NULL) return;
struct string_array *this = *array; struct string_array *this = *array;
DBG_STRING(printf("%s: address: %p\n", __func__, this);) DBG_STRING(printf("%s: address: %p\n", __func__, this);)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment