summaryrefslogtreecommitdiffstats
path: root/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'main.c')
-rw-r--r--main.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/main.c b/main.c
index 4dc73df1..3f36234d 100644
--- a/main.c
+++ b/main.c
@@ -790,8 +790,14 @@ fs_search(const struct mansearch *cfg, const struct manpaths *paths,
return 1;
}
if (res != NULL && *ressz == lastsz &&
- strchr(*argv, '/') == NULL)
- warnx("No entry for %s in the manual.", *argv);
+ strchr(*argv, '/') == NULL) {
+ if (cfg->sec == NULL)
+ warnx("No entry for %s in the manual.",
+ *argv);
+ else
+ warnx("No entry for %s in section %s "
+ "of the manual.", *argv, cfg->sec);
+ }
lastsz = *ressz;
argv++;
argc--;