[systemd-devel] [PATCH] install: create_symlink() check unlink() return value

2014-04-16 Thread Djalal Harouni
create_symlink() do not check the return value of unlink(), this may confuse the user. Before the unlink() call we check the 'force' argument. If it is not set we fail with -EEXIST, otherwise we unlink() the file, therefore the next symlink() should not fail with -EEXIST (do not count races...).

Re: [systemd-devel] [PATCH] install: create_symlink() check unlink() return value

2014-04-16 Thread Zbigniew Jędrzejewski-Szmek
On Thu, Apr 17, 2014 at 01:47:11AM +0100, Djalal Harouni wrote: create_symlink() do not check the return value of unlink(), this may confuse the user. Before the unlink() call we check the 'force' argument. If it is not set we fail with -EEXIST, otherwise we unlink() the file, therefore the