commit 7b6298d198c875c7d5036f0a8ad81c4a0ea194f9 Author: Ulrich Spörlein Date: Mon May 24 16:50:14 2010 +0200 mandoc: cut trailing OS string after first dash This is to mimick groff behaviour, where only "FreeBSD 8.0" is displayed in the footer. diff --git a/contrib/mdocml/mdoc_action.c b/contrib/mdocml/mdoc_action.c index f27ef13..ddd7cab 100644 --- a/contrib/mdocml/mdoc_action.c +++ b/contrib/mdocml/mdoc_action.c @@ -611,6 +611,8 @@ post_os(POST_ARGS) mdoc_nmsg(m, n, MANDOCERR_MEM); return(0); } + if (strncmp(utsname.sysname, "FreeBSD", sizeof("FreeBSD")) == 0) + strtok(utsname.release, "-"); if (strlcat(buf, utsname.release, BUFSIZ) >= BUFSIZ) { mdoc_nmsg(m, n, MANDOCERR_MEM); return(0);