summaryrefslogtreecommitdiff
path: root/src/home/homework-luks.c
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2022-07-02 16:59:32 +0200
committerGitHub <noreply@github.com>2022-07-02 16:59:32 +0200
commit7b3b2e5ad6a99e5089165ec3c9c2b2756ae5503e (patch)
tree39867466450014925ceeae31bd81df47a9faaa55 /src/home/homework-luks.c
parentddbc88188c01606d355befdbc3982d58369491eb (diff)
parent1474e66a52c2d53aed91b101b9dc5fbb632b303c (diff)
downloadsystemd-7b3b2e5ad6a99e5089165ec3c9c2b2756ae5503e.tar.gz
Merge pull request #23865 from keszybz/drop-memcpy-call
sd-id128: avoid an unnecessary function call in inline helper
Diffstat (limited to 'src/home/homework-luks.c')
-rw-r--r--src/home/homework-luks.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/home/homework-luks.c b/src/home/homework-luks.c
index 97269db80d..0108ab5407 100644
--- a/src/home/homework-luks.c
+++ b/src/home/homework-luks.c
@@ -180,7 +180,7 @@ static int probe_file_system_by_path(const char *path, char **ret_fstype, sd_id1
fd = open(path, O_RDONLY|O_CLOEXEC|O_NOCTTY|O_NONBLOCK);
if (fd < 0)
- return -errno;
+ return negative_errno();
return probe_file_system_by_fd(fd, ret_fstype, ret_uuid);
}
@@ -1230,7 +1230,7 @@ int home_setup_luks(
PasswordCache *cache,
UserRecord **ret_luks_home) {
- sd_id128_t found_partition_uuid = SD_ID128_NULL, found_luks_uuid = SD_ID128_NULL, found_fs_uuid = SD_ID128_NULL;
+ sd_id128_t found_partition_uuid, found_fs_uuid, found_luks_uuid = SD_ID128_NULL;
_cleanup_(user_record_unrefp) UserRecord *luks_home = NULL;
_cleanup_(erase_and_freep) void *volume_key = NULL;
size_t volume_key_size = 0;