From e83011c85d800549acd7ba17bee6e45ff659148c Mon Sep 17 00:00:00 2001 From: Christian Hergert Date: Tue, 9 May 2023 13:30:02 -0700 Subject: [PATCH] libysysprof-analyze: make ref string transfer full No reason to have extra unref's by the caller for these. --- src/libsysprof-analyze/sysprof-symbol.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/libsysprof-analyze/sysprof-symbol.c b/src/libsysprof-analyze/sysprof-symbol.c index 66c03c12..8aef2561 100644 --- a/src/libsysprof-analyze/sysprof-symbol.c +++ b/src/libsysprof-analyze/sysprof-symbol.c @@ -140,16 +140,16 @@ sysprof_symbol_get_binary_path (SysprofSymbol *self) } SysprofSymbol * -_sysprof_symbol_new (char *name, - char *binary_path, - char *binary_nick) +_sysprof_symbol_new (GRefString *name, + GRefString *binary_path, + GRefString *binary_nick) { SysprofSymbol *self; self = g_object_new (SYSPROF_TYPE_SYMBOL, NULL); - self->name = name ? g_ref_string_acquire (name) : NULL; - self->binary_path = binary_path ? g_ref_string_acquire (binary_path) : NULL; - self->binary_nick = binary_nick ? g_ref_string_acquire (binary_nick) : NULL; + self->name = name; + self->binary_path = binary_path; + self->binary_nick = binary_nick; return self; }