mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-05-04 23:28:08 +02:00
cli: clarify generic getter alloc/free behavior
This commit is contained in:
parent
229cba8354
commit
e09550ec62
1 changed files with 3 additions and 0 deletions
|
|
@ -780,6 +780,9 @@ vpn_data_item (const char *key, const char *value, gpointer user_data)
|
|||
GValue val = G_VALUE_INIT; \
|
||||
g_value_init (&val, G_TYPE_STRING); \
|
||||
g_object_get_property (G_OBJECT (setting), property_name, &val); \
|
||||
/* Getters return allocated values, and returning the string \
|
||||
* the GValue copied from the object without unsetting the \
|
||||
* GValue fulfills that requirement. */ \
|
||||
return (char *) g_value_get_string (&val); \
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue