diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/src/lookups/dsearch.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/src/lookups/dsearch.c b/src/src/lookups/dsearch.c index dba8422cc..07931ae4a 100644 --- a/src/src/lookups/dsearch.c +++ b/src/src/lookups/dsearch.c @@ -52,8 +52,11 @@ dsearch_check(void * handle, const uschar * filename, int modemask, uid_t * owners, gid_t * owngroups, uschar ** errmsg) { handle = handle; -return lf_check_file(-1, filename, S_IFDIR, modemask, owners, owngroups, - "dsearch", errmsg) == 0; +if (*filename == '/') + return lf_check_file(-1, filename, S_IFDIR, modemask, owners, owngroups, + "dsearch", errmsg) == 0; +*errmsg = string_sprintf("dirname '%s' for dsearch is not absolute", filename); +return FALSE; } |