diff --git a/libdfu/dfu-context.c b/libdfu/dfu-context.c index 0174ae171..3fc188df5 100644 --- a/libdfu/dfu-context.c +++ b/libdfu/dfu-context.c @@ -481,8 +481,8 @@ dfu_context_get_device_by_vid_pid (DfuContext *context, GUsbDevice *dev; guint i; - g_return_val_if_fail (DFU_IS_CONTEXT (context), FALSE); - g_return_val_if_fail (error == NULL || *error == NULL, FALSE); + g_return_val_if_fail (DFU_IS_CONTEXT (context), NULL); + g_return_val_if_fail (error == NULL || *error == NULL, NULL); /* search all devices */ for (i = 0; i < priv->devices->len; i++) { @@ -536,8 +536,8 @@ dfu_context_get_device_by_platform_id (DfuContext *context, DfuContextItem *item; guint i; - g_return_val_if_fail (DFU_IS_CONTEXT (context), FALSE); - g_return_val_if_fail (error == NULL || *error == NULL, FALSE); + g_return_val_if_fail (DFU_IS_CONTEXT (context), NULL); + g_return_val_if_fail (error == NULL || *error == NULL, NULL); /* search all devices */ for (i = 0; i < priv->devices->len; i++) { @@ -573,8 +573,8 @@ dfu_context_get_device_default (DfuContext *context, GError **error) DfuContextPrivate *priv = GET_PRIVATE (context); DfuContextItem *item; - g_return_val_if_fail (DFU_IS_CONTEXT (context), FALSE); - g_return_val_if_fail (error == NULL || *error == NULL, FALSE); + g_return_val_if_fail (DFU_IS_CONTEXT (context), NULL); + g_return_val_if_fail (error == NULL || *error == NULL, NULL); /* none */ if (priv->devices->len == 0) { diff --git a/libdfu/dfu-device.c b/libdfu/dfu-device.c index 4d85bac8a..dc2aa44de 100644 --- a/libdfu/dfu-device.c +++ b/libdfu/dfu-device.c @@ -1700,7 +1700,7 @@ dfu_device_upload (DfuDevice *device, DFU_ERROR, DFU_ERROR_NOT_SUPPORTED, "device is not in DFU mode"); - return FALSE; + return NULL; } g_debug ("detaching"); diff --git a/libdfu/dfu-firmware.c b/libdfu/dfu-firmware.c index b2985eea3..affdfc61c 100644 --- a/libdfu/dfu-firmware.c +++ b/libdfu/dfu-firmware.c @@ -716,7 +716,7 @@ dfu_firmware_write_data_ihex (DfuFirmware *firmware, GError **error) if (!dfu_firmware_write_data_ihex_element (element, str, error)) - return FALSE; + return NULL; } } diff --git a/libdfu/dfu-target.c b/libdfu/dfu-target.c index 9f6f32c88..8893fb7a6 100644 --- a/libdfu/dfu-target.c +++ b/libdfu/dfu-target.c @@ -917,7 +917,7 @@ dfu_target_upload_chunk (DfuTarget *target, guint8 index, /* for ST devices, the action only occurs when we do GetStatus */ if (!dfu_device_has_quirk (priv->device, DFU_DEVICE_QUIRK_NO_GET_STATUS_UPLOAD)) { if (!dfu_target_check_status (target, cancellable, error)) - return FALSE; + return NULL; } return g_bytes_new_take (buf, actual_length); @@ -970,7 +970,7 @@ dfu_target_upload_element (DfuTarget *target, DFU_ERROR_INVALID_DEVICE, "no memory sector at 0x%04x", (guint) offset); - return FALSE; + return NULL; } if (!dfu_sector_has_cap (sector, DFU_SECTOR_CAP_READABLE)) { g_set_error (error, @@ -978,7 +978,7 @@ dfu_target_upload_element (DfuTarget *target, DFU_ERROR_INVALID_DEVICE, "memory sector at 0x%04x is not readble", (guint) offset); - return FALSE; + return NULL; } /* manually set the sector address */ @@ -988,7 +988,7 @@ dfu_target_upload_element (DfuTarget *target, offset, cancellable, error)) - return FALSE; + return NULL; last_sector_id = dfu_sector_get_id (sector); } } @@ -1533,7 +1533,7 @@ dfu_target_get_alt_name (DfuTarget *target, GError **error) DFU_ERROR, DFU_ERROR_NOT_FOUND, "no alt-name"); - return FALSE; + return NULL; } return priv->alt_name;