trivial: Fix up some warnings spotted by new GCC

This commit is contained in:
Richard Hughes 2016-06-07 10:11:00 +01:00
parent 4580ed128b
commit 11dc9ace51
2 changed files with 3 additions and 8 deletions

View File

@ -1177,8 +1177,7 @@ dfu_tool_device_added_cb (DfuContext *context,
gpointer user_data)
{
DfuToolPrivate *priv = (DfuToolPrivate *) user_data;
g_autofree gchar *tmp;
tmp = dfu_tool_get_device_string (priv, device);
g_autofree gchar *tmp = dfu_tool_get_device_string (priv, device);
/* TRANSLATORS: this is when a device is hotplugged */
dfu_tool_print_indent (_("Added"), tmp, 0);
}
@ -1192,8 +1191,7 @@ dfu_tool_device_removed_cb (DfuContext *context,
gpointer user_data)
{
DfuToolPrivate *priv = (DfuToolPrivate *) user_data;
g_autofree gchar *tmp;
tmp = dfu_tool_get_device_string (priv, device);
g_autofree gchar *tmp = dfu_tool_get_device_string (priv, device);
/* TRANSLATORS: this is when a device is hotplugged */
dfu_tool_print_indent (_("Removed"), tmp, 0);
}
@ -1205,8 +1203,7 @@ static void
dfu_tool_device_changed_cb (DfuContext *context, DfuDevice *device, gpointer user_data)
{
DfuToolPrivate *priv = (DfuToolPrivate *) user_data;
g_autofree gchar *tmp;
tmp = dfu_tool_get_device_string (priv, device);
g_autofree gchar *tmp = dfu_tool_get_device_string (priv, device);
/* TRANSLATORS: this is when a device is hotplugged */
dfu_tool_print_indent (_("Changed"), tmp, 0);
}

View File

@ -50,7 +50,6 @@ fu_plugin_device_probe (FuPlugin *plugin, FuDevice *device, GError **error)
gboolean ret;
gsize actual_len = 0;
guint8 data[32];
guint i;
g_autofree gchar *version = NULL;
g_autoptr(GUsbContext) usb_ctx = NULL;
g_autoptr(GUsbDevice) usb_device = NULL;
@ -150,7 +149,6 @@ fu_plugin_device_update (FuPlugin *plugin,
GError **error)
{
const gchar *platform_id;
const gchar *vendor_driver;
g_autoptr(GUsbContext) usb_ctx = NULL;
g_autoptr(GUsbDevice) usb_device = NULL;
g_autoptr(GUsbDevice) usb_devnew = NULL;