mirror of
https://github.com/systemd/systemd.git
synced 2024-11-02 02:21:44 +03:00
rc-local-generator: small shortification
This commit is contained in:
parent
278ef0ab33
commit
c5df80a06d
@ -21,7 +21,6 @@ static const char *arg_dest = "/tmp";
|
||||
|
||||
static int add_symlink(const char *service, const char *where) {
|
||||
const char *from, *to;
|
||||
int r;
|
||||
|
||||
assert(service);
|
||||
assert(where);
|
||||
@ -31,8 +30,7 @@ static int add_symlink(const char *service, const char *where) {
|
||||
|
||||
(void) mkdir_parents_label(to, 0755);
|
||||
|
||||
r = symlink(from, to);
|
||||
if (r < 0) {
|
||||
if (symlink(from, to) < 0) {
|
||||
if (errno == EEXIST)
|
||||
return 0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user