summaryrefslogtreecommitdiff
path: root/src/libsystemd/sd-device/device-private.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libsystemd/sd-device/device-private.c')
-rw-r--r--src/libsystemd/sd-device/device-private.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/libsystemd/sd-device/device-private.c b/src/libsystemd/sd-device/device-private.c
index 2e60433246..0ec9667744 100644
--- a/src/libsystemd/sd-device/device-private.c
+++ b/src/libsystemd/sd-device/device-private.c
@@ -1082,12 +1082,10 @@ int device_update_db(sd_device *device) {
return 0;
fail:
- log_error_errno(r, "failed to create %s file '%s' for '%s'", has_info ? "db" : "empty",
- path, device->devpath);
- unlink(path);
- unlink(path_tmp);
+ (void) unlink(path);
+ (void) unlink(path_tmp);
- return r;
+ return log_error_errno(r, "failed to create %s file '%s' for '%s'", has_info ? "db" : "empty", path, device->devpath);
}
int device_delete_db(sd_device *device) {