summaryrefslogtreecommitdiff
path: root/shell-completion/bash/systemd-resolve
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2019-10-24 10:33:20 +0200
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2019-10-24 10:33:20 +0200
commit7abeefa9f9e55592db14f3fdafc01ea8f90311e4 (patch)
treef91422895ffeda469dabd808cd4155d76638cc81 /shell-completion/bash/systemd-resolve
parent235ecb6d75f00384b3f42f449c769340e13fbd0b (diff)
downloadsystemd-chase-symlinks-rework.tar.gz
basic/fs-util: change CHASE_OPEN flag into a separate output parameterchase-symlinks-rework
chase_symlinks() would return negative on error, and either a non-negative status or a non-negative fd when CHASE_OPEN was given. This made the interface quite complicated, because dependning on the flags used, we would get two different "types" of return object. Coverity was always confused by this, and flagged every use of chase_symlinks() without CHASE_OPEN as a resource leak (because it would this that an fd is returned). This patch uses a saparate output parameter, so there is no confusion. (I think it is OK to have functions which return either an error or an fd. It's only returning *either* an fd or a non-fd that is confusing.)
Diffstat (limited to 'shell-completion/bash/systemd-resolve')
0 files changed, 0 insertions, 0 deletions