summaryrefslogtreecommitdiff
path: root/src/man2html/yelp-man2html.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/man2html/yelp-man2html.c')
-rw-r--r--src/man2html/yelp-man2html.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/man2html/yelp-man2html.c b/src/man2html/yelp-man2html.c
index c021fa78..1e2b6162 100644
--- a/src/man2html/yelp-man2html.c
+++ b/src/man2html/yelp-man2html.c
@@ -3762,6 +3762,16 @@ main(int argc, char **argv)
infile = argv[i];
}
+ if (g_file_test(infile, G_FILE_TEST_IS_DIR)) {
+ printf("<HTML><HEAD><TITLE>Document not found</TITLE>\n"
+ "</HEAD><BODY>"
+ "I don't know how to open the document \"%s\" "
+ "on your system.\n"
+ "</BODY></HTML>\n", infile);
+
+ return 4;
+ }
+
if(!infile || !strcmp(infile, "-"))
infh = gzdopen(0, "r");
else