diff options
author | Ingo Schwarze <schwarze@openbsd.org> | 2017-05-17 21:19:32 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@openbsd.org> | 2017-05-17 21:19:32 +0000 |
commit | fbb27951be5b224a8e3f34ecf1a4750a3eaf2b3f (patch) | |
tree | b330e7b9ab687482991e9cb63569f706061b5dd6 | |
parent | 0051e5a1d4917fc98592d104bb751a4b0d5d9fd0 (diff) | |
download | mandoc-fbb27951be5b224a8e3f34ecf1a4750a3eaf2b3f.tar.gz |
Do not warn if a database file does not exist
because that is simply equivalent to an empty database.
Suggested by ajacoutot@
-rw-r--r-- | mansearch.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/mansearch.c b/mansearch.c index d7444137..26a7c23f 100644 --- a/mansearch.c +++ b/mansearch.c @@ -155,7 +155,8 @@ mansearch(const struct mansearch *search, chdir_status = 1; if (dbm_open(MANDOC_DB) == -1) { - warn("%s/%s", paths->paths[i], MANDOC_DB); + if (errno != ENOENT) + warn("%s/%s", paths->paths[i], MANDOC_DB); continue; } |