mirror of
https://github.com/varun-r-mallya/sysprof.git
synced 2025-12-31 20:36:25 +00:00
libsysprof-capture: wrap strdup to be NULL-safe
This commit is contained in:
committed by
Philip Withnall
parent
6a45f020f7
commit
cef698e658
@ -519,7 +519,7 @@ sysprof_capture_condition_new_where_file (const char *path)
|
||||
return NULL;
|
||||
|
||||
self->type = SYSPROF_CAPTURE_CONDITION_WHERE_FILE;
|
||||
self->u.where_file = strdup (path);
|
||||
self->u.where_file = sysprof_strdup (path);
|
||||
if (self->u.where_file == NULL)
|
||||
{
|
||||
free (self);
|
||||
|
||||
Reference in New Issue
Block a user