diff options
author | Yuri Pankov <yuri.pankov@nexenta.com> | 2015-10-18 14:22:06 +0300 |
---|---|---|
committer | Gordon Ross <gwr@nexenta.com> | 2015-11-03 15:48:48 -0500 |
commit | 260e9a87725c090ba5835b1f9f0b62fa2f96036f (patch) | |
tree | 46ce875eadee4e0fa3586128cacfea38e5b15569 /usr/src/cmd/man/man.c | |
parent | 1058dba45ec5d6876a5bbb0b9174347e13e5748d (diff) | |
download | illumos-joyent-260e9a87725c090ba5835b1f9f0b62fa2f96036f.tar.gz |
6356 Update mdocml to 1.13.3
Reviewed by: Toomas Soome <tsoome@me.com>
Reviewed by: Igor Kozhukhov <ikozhukhov@gmail.com>
Approved by: Gordon Ross <gwr@nexenta.com>
Diffstat (limited to 'usr/src/cmd/man/man.c')
-rw-r--r-- | usr/src/cmd/man/man.c | 23 |
1 files changed, 7 insertions, 16 deletions
diff --git a/usr/src/cmd/man/man.c b/usr/src/cmd/man/man.c index 8038cabbac..d181c6d374 100644 --- a/usr/src/cmd/man/man.c +++ b/usr/src/cmd/man/man.c @@ -22,8 +22,8 @@ /* * Copyright (c) 1990, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright 2012, Josef 'Jeff' Sipek <jeffpc@31bits.net>. All rights reserved. - * Copyright 2013 Nexenta Systems, Inc. All rights reserved. * Copyright 2014 Garrett D'Amore <garrett@damore.org> + * Copyright 2015 Nexenta Systems, Inc. All rights reserved. */ /* Copyright (c) 1983, 1984, 1985, 1986, 1987, 1988, 1989 AT&T. */ @@ -1193,7 +1193,6 @@ format(char *path, char *dir, char *name, char *pg) char manpname[MAXPATHLEN], catpname[MAXPATHLEN]; char cmdbuf[BUFSIZ], tmpbuf[BUFSIZ]; char *cattool; - int utf8 = 0; struct stat sbman, sbcat; found++; @@ -1227,22 +1226,16 @@ format(char *path, char *dir, char *name, char *pg) else cattool = "cat"; - /* Preprocess UTF-8 input with preconv (could be smarter) */ - if (strstr(path, "UTF-8") != NULL) - utf8 = 1; - if (psoutput) { (void) snprintf(cmdbuf, BUFSIZ, - "cd %s; %s %s%s | mandoc -Tps | lp -Tpostscript", - path, cattool, manpname, - utf8 ? " | " PRECONV " -e UTF-8" : ""); + "cd %s; %s %s | mandoc -Tps | lp -Tpostscript", + path, cattool, manpname); DPRINTF("-- Using manpage: %s\n", manpname); goto cmd; } else if (lintout) { (void) snprintf(cmdbuf, BUFSIZ, - "cd %s; %s %s%s | mandoc -Tlint", - path, cattool, manpname, - utf8 ? " | " PRECONV " -e UTF-8" : ""); + "cd %s; %s %s | mandoc -Tlint", + path, cattool, manpname); DPRINTF("-- Linting manpage: %s\n", manpname); goto cmd; } @@ -1262,10 +1255,8 @@ format(char *path, char *dir, char *name, char *pg) DPRINTF("-- Using manpage: %s\n", manpname); if (manwidth > 0) (void) snprintf(tmpbuf, BUFSIZ, "-Owidth=%d ", manwidth); - (void) snprintf(cmdbuf, BUFSIZ, "cd %s; %s %s%s | mandoc -T%s %s| %s", - path, cattool, manpname, - utf8 ? " | " PRECONV " -e UTF-8 " : "", - utf8 ? "utf8" : "ascii", (manwidth > 0) ? tmpbuf : "", pager); + (void) snprintf(cmdbuf, BUFSIZ, "cd %s; %s %s | mandoc %s| %s", + path, cattool, manpname, (manwidth > 0) ? tmpbuf : "", pager); cmd: DPRINTF("-- Command: %s\n", cmdbuf); |