base: Fix leak in heim_string_create_with_format()

This commit is contained in:
Nicolas Williams
2020-08-28 22:30:56 -05:00
parent a2d827ca1d
commit faee4626fb

View File

@@ -182,7 +182,7 @@ heim_string_create_with_format(const char *fmt, ...)
if (ret < 0 || str == NULL)
return NULL;
s = heim_string_ref_create(str, string_dealloc);
s = heim_string_ref_create(str, free);
if (s == NULL)
free(str);
return s;