Skip to content

Commit

Permalink
gtkui: medialib cover art pixbuf reference counting fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Oleksiy-Yakovenko committed Nov 17, 2023
1 parent d66414b commit ebc525f
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions plugins/gtkui/medialib/mlcellrendererpixbuf.c
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,14 @@ _set_property (
break;
}
case PROP_PIXBUF:
if (cellpixbuf->pixbuf != NULL) {
g_object_unref (cellpixbuf->pixbuf);
cellpixbuf->pixbuf = NULL;
}
cellpixbuf->pixbuf = g_value_get_object (value);
if (cellpixbuf->pixbuf != NULL) {
g_object_ref (cellpixbuf->pixbuf);
}
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, param_id, pspec);
Expand Down

0 comments on commit ebc525f

Please sign in to comment.