From 6336fb379694f5535d4a3faac30664eb79b72991 Mon Sep 17 00:00:00 2001 From: Ingo Schwarze Date: Sun, 24 Jan 2016 20:10:49 +0000 Subject: In the OpenBSD-specific part of verify_xref(), discard the standard error output from man -f: Messages "man: nothing appropriate" are not helpful. If no matching manual exists anywhere, a more specific message follows right afterwards. If a matching manual exists in the current directory, such messages are just wrong. Issue reported by jmc@. --- regress/usr.bin/mdoclint/mdoclint | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'regress/usr.bin/mdoclint') diff --git a/regress/usr.bin/mdoclint/mdoclint b/regress/usr.bin/mdoclint/mdoclint index 11ed090db38..95f1250a683 100644 --- a/regress/usr.bin/mdoclint/mdoclint +++ b/regress/usr.bin/mdoclint/mdoclint @@ -1,6 +1,6 @@ #!/usr/bin/perl # -# $OpenBSD: mdoclint,v 1.47 2015/12/06 08:55:09 schwarze Exp $ +# $OpenBSD: mdoclint,v 1.48 2016/01/24 20:10:48 schwarze Exp $ # $NetBSD: mdoclint,v 1.49 2014/06/23 18:10:21 wiz Exp $ # # Copyright (c) 2001-2013 Thomas Klausner @@ -274,10 +274,13 @@ sub verify_xref # try to find corresponding man page if (OPENBSD) { open my $saveout, '>&', STDOUT; + open my $saveerr, '>&', STDERR; open STDOUT, '>', '/dev/null'; + open STDERR, '>', '/dev/null'; my $irc = system 'man', '-M', '/usr/share/man:/usr/X11R6/man', '-s', $section, '-f', $page; open STDOUT, '>&', $saveout; + open STDERR, '>&', $saveerr; return 1 unless $irc; } else { for my $dir ('/usr/share/man', '/usr/X11R7/man') { -- cgit v1.2.3