trivial: Fix two warnings in the win32 build

This commit is contained in:
Richard Hughes 2020-09-24 09:19:15 +01:00
parent da17ff4888
commit 6b5926ca59
2 changed files with 4 additions and 10 deletions

View File

@ -69,13 +69,13 @@ fu_efivar_supported (GError **error)
#endif
}
#ifndef _WIN32
static gboolean
fu_efivar_set_immutable_fd (int fd,
gboolean value,
gboolean *value_old,
GError **error)
{
#ifndef _WIN32
guint flags;
gboolean is_immutable;
int rc;
@ -124,14 +124,8 @@ fu_efivar_set_immutable_fd (int fd,
return FALSE;
}
return TRUE;
#else
g_set_error_literal (error,
FWUPD_ERROR,
FWUPD_ERROR_NOT_SUPPORTED,
"efivarfs not currently supported on Windows");
return FALSE;
#endif
}
#endif
static gboolean
fu_efivar_set_immutable (const gchar *fn,

View File

@ -195,10 +195,10 @@ fu_udev_device_set_device_file (FuUdevDevice *self, const gchar *device_file)
g_object_notify (G_OBJECT (self), "device-file");
}
#ifdef HAVE_GUDEV
static const gchar *
fu_udev_device_get_vendor_fallback (GUdevDevice *udev_device)
{
#ifdef HAVE_GUDEV
const gchar *tmp;
tmp = g_udev_device_get_property (udev_device, "ID_VENDOR_FROM_DATABASE");
if (tmp != NULL)
@ -206,9 +206,9 @@ fu_udev_device_get_vendor_fallback (GUdevDevice *udev_device)
tmp = g_udev_device_get_property (udev_device, "ID_VENDOR");
if (tmp != NULL)
return tmp;
#endif
return NULL;
}
#endif
#ifdef HAVE_GUDEV
static gboolean