SHA256
1
0
forked from pool/man
man/man-db-2.7.1-firefox.dif

48 lines
1.3 KiB
Plaintext
Raw Normal View History

---
src/man.c | 22 ++++++++++++----------
1 file changed, 12 insertions(+), 10 deletions(-)
--- src/man.c
+++ src/man.c 2016-12-15 14:02:44.261219082 +0000
@@ -1949,16 +1949,6 @@ static void format_display (pipeline *de
if (!disp_status)
break;
}
- if (!candidate) {
- if (html_pager && *html_pager)
- error (CHILD_FAIL, 0,
- "couldn't execute any browser from %s",
- html_pager);
- else
- error (CHILD_FAIL, 0,
- "no browser configured, so cannot show "
- "HTML output");
- }
free (browser_list);
if (have_old_cwd && restore_cwd (&old_cwd) < 0) {
error (0, errno,
@@ -1967,11 +1957,23 @@ static void format_display (pipeline *de
if (chdir ("/")) { /* ignore errors */ }
}
free_cwd (&old_cwd);
+ if (!disp_status)
+ sleep (5); /* firefox runs into background to fast */
if (remove_directory (htmldir, 0) == -1)
error (0, errno, _("can't remove directory %s"),
htmldir);
free (htmlfile);
free (htmldir);
+ if (!candidate) {
+ if (html_pager && *html_pager)
+ error (CHILD_FAIL, 0,
+ "couldn't execute any browser from %s",
+ html_pager);
+ else
+ error (CHILD_FAIL, 0,
+ "no browser configured, so cannot show "
+ "HTML output");
+ }
} else
#endif /* TROFF_IS_GROFF */
{