diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2010-01-14 00:14:06 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2010-01-14 00:14:06 +0000 |
commit | 0fba3bef558036952f59846a7e7b48e1f5b9e479 (patch) | |
tree | 9e521a1e2ea5abfe93e5ae83795941c1eccc2761 /src/backend/access/gist/gistproc.c | |
parent | 715120e7ac9f80eec4e5d5c011cd151675ad59d1 (diff) | |
download | postgresql-0fba3bef558036952f59846a7e7b48e1f5b9e479.tar.gz |
Simplify validate_exec() by using access(2) to check file permissions,
rather than trying to implement the equivalent logic by hand. The motivation
for the original coding appears to have been to check with the effective uid's
permissions not the real uid's; but there is no longer any difference, because
we don't run the postmaster setuid (indeed, main.c enforces that they're the
same). Using access() means we will get it right in situations the original
coding failed to handle, such as ACL-based permissions. Besides it's a lot
shorter, cleaner, and more thread-safe. Per bug #5275 from James Bellinger.
Diffstat (limited to 'src/backend/access/gist/gistproc.c')
0 files changed, 0 insertions, 0 deletions