diff options
author | Guillem Jover <guillem@debian.org> | 2009-12-26 22:05:20 +0100 |
---|---|---|
committer | Guillem Jover <guillem@debian.org> | 2009-12-31 20:51:51 +0100 |
commit | 07d3faf8c7bc338717fa7e1fed3698d316dc5454 (patch) | |
tree | 15c3bb1e4864abff09ed4bfa9e4ebc0ddda22af2 /utils | |
parent | dde9a226d5f831c773539ee8c58f861148fd7c5e (diff) | |
download | dpkg-07d3faf8c7bc338717fa7e1fed3698d316dc5454.tar.gz |
install-info: Do not use access() to check for exec permission
Just try to execute the file and deal with the error if any.
Diffstat (limited to 'utils')
-rw-r--r-- | utils/install-info.c | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/utils/install-info.c b/utils/install-info.c index 8351390fd..0b831a1d3 100644 --- a/utils/install-info.c +++ b/utils/install-info.c @@ -46,11 +46,7 @@ main(int argc, char **argv) warn("its replacement lives in /usr/bin/.\n"); } - if (access(WRAPPED, X_OK) == 0) { execv(WRAPPED, argv); - error("can't execute %s: %s\n", WRAPPED, strerror(errno)); - return 1; /* exec failed */ - } else { if (errno == ENOENT) { if (getenv("DPKG_RUNNING_VERSION") != NULL) { const char *pkg; @@ -69,7 +65,6 @@ main(int argc, char **argv) error("can't execute %s: %s\n", WRAPPED, strerror(errno)); return 1; } - } return 0; } |