diff options
author | Jens Georg <mail@jensge.org> | 2021-10-28 17:45:51 +0200 |
---|---|---|
committer | Jens Georg <mail@jensge.org> | 2021-10-28 17:45:51 +0200 |
commit | b5ed6be7afa44102cb0484106af2fa5676e51d68 (patch) | |
tree | d5463c6c70a9fa86daebe3bcd569304e6e6cdedc | |
parent | 723f24ab3c5ee4db1b5e25f7c05ab18862a58e33 (diff) | |
download | gssdp-b5ed6be7afa44102cb0484106af2fa5676e51d68.tar.gz |
SocketSource: Small code clean-up
-rw-r--r-- | libgssdp/gssdp-socket-source.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/libgssdp/gssdp-socket-source.c b/libgssdp/gssdp-socket-source.c index 438ca82..6cb0a66 100644 --- a/libgssdp/gssdp-socket-source.c +++ b/libgssdp/gssdp-socket-source.c @@ -345,10 +345,9 @@ gssdp_socket_source_do_init (GInitable *initable, success = TRUE; error: - if (bind_address != NULL) - g_object_unref (bind_address); - if (group != NULL) - g_object_unref (group); + g_clear_object (&bind_address); + g_clear_object (&group); + if (!success) /* Be aware that inner_error has already been free'd by * g_propagate_error(), so we cannot access its contents |