diff options
author | Michal Schmidt <mschmidt@redhat.com> | 2014-11-28 19:57:32 +0100 |
---|---|---|
committer | Anthony G. Basile <blueness@gentoo.org> | 2014-12-01 13:13:40 -0500 |
commit | f460aa149c21c920e1a3090a16877937c49b4813 (patch) | |
tree | ede02852a05f16790224d29a48de551b8ab87d8d /src/udev/udev-rules.c | |
parent | 761b969283f415df75efe2ffb772a62b23379222 (diff) |
treewide: another round of simplifications
Using the same scripts as in f647962d64e "treewide: yet more log_*_errno
+ return simplifications".
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
Diffstat (limited to 'src/udev/udev-rules.c')
-rw-r--r-- | src/udev/udev-rules.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/udev/udev-rules.c b/src/udev/udev-rules.c index 5e901598f5..ddbde5a784 100644 --- a/src/udev/udev-rules.c +++ b/src/udev/udev-rules.c @@ -2719,10 +2719,10 @@ int udev_rules_apply_static_dev_perms(struct udev_rules *rules) { strscpyl(tag_symlink, sizeof(tag_symlink), tags_dir, unescaped_filename, NULL); r = symlink(device_node, tag_symlink); - if (r < 0 && errno != EEXIST) { - log_error_errno(errno, "failed to create symlink %s -> %s: %m", tag_symlink, device_node); - return -errno; - } else + if (r < 0 && errno != EEXIST) + return log_error_errno(errno, "failed to create symlink %s -> %s: %m", + tag_symlink, device_node); + else r = 0; } } |