mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-04-24 16:16:52 +02:00
gio/gvolumemonitor: Suggest disconnecting signals
It is easy to overlook that unreffing a GVolumeMonitor doesn't disconnect signal handlers, this can lead to segfaults from dangling user data pointers.
This commit is contained in:
parent
4738951270
commit
6119bb0042
@ -507,7 +507,7 @@ g_union_volume_monitor_new (void)
|
|||||||
* Gets the volume monitor used by gio.
|
* Gets the volume monitor used by gio.
|
||||||
*
|
*
|
||||||
* Returns: (transfer full): a reference to the #GVolumeMonitor used by gio. Call
|
* Returns: (transfer full): a reference to the #GVolumeMonitor used by gio. Call
|
||||||
* g_object_unref() when done with it.
|
* g_object_unref() when done with it, after disconnecting any signal handlers.
|
||||||
**/
|
**/
|
||||||
GVolumeMonitor *
|
GVolumeMonitor *
|
||||||
g_volume_monitor_get (void)
|
g_volume_monitor_get (void)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user