mirror of
https://git.proxmox.com/git/fwupd
synced 2025-05-28 20:46:06 +00:00
Fix a refcounting issue in the udev plugin
Objects are returned from the cache with transfer:none. Hopefully fixes https://github.com/hughsie/fwupd/issues/86
This commit is contained in:
parent
6ad951d27c
commit
48d23f7bb0
@ -112,6 +112,7 @@ fu_plugin_verify (FuPlugin *plugin,
|
||||
static void
|
||||
fu_plugin_udev_add (FuPlugin *plugin, GUdevDevice *device)
|
||||
{
|
||||
FuDevice *dev_tmp;
|
||||
const gchar *display_name;
|
||||
const gchar *guid;
|
||||
const gchar *product;
|
||||
@ -136,8 +137,8 @@ fu_plugin_udev_add (FuPlugin *plugin, GUdevDevice *device)
|
||||
|
||||
/* is already in database */
|
||||
id = fu_plugin_udev_get_id (device);
|
||||
dev = fu_plugin_cache_lookup (plugin, id);
|
||||
if (dev != NULL) {
|
||||
dev_tmp = fu_plugin_cache_lookup (plugin, id);
|
||||
if (dev_tmp != NULL) {
|
||||
g_debug ("ignoring duplicate %s", id);
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user