X-Git-Url: https://git.openssl.org/gitweb/?p=openssl.git;a=blobdiff_plain;f=util%2Ffind-doc-nits;h=860bb9958bd2d8b7d86e0b962009fa2e286d2923;hp=aaf3eeb4f0d9a91ef180adb3bb7dd16dda608c5d;hb=fce1b86f61e183d3b73a51d2077ec2719291b756;hpb=0ed78e78007bb74e48e6f59fa2388bb244153bf0 diff --git a/util/find-doc-nits b/util/find-doc-nits index aaf3eeb4f0..860bb9958b 100755 --- a/util/find-doc-nits +++ b/util/find-doc-nits @@ -1,5 +1,5 @@ #! /usr/bin/env perl -# Copyright 2002-2016 The OpenSSL Project Authors. All Rights Reserved. +# Copyright 2002-2018 The OpenSSL Project Authors. All Rights Reserved. # # Licensed under the OpenSSL license (the "License"). You may not use # this file except in compliance with the License. You can obtain a copy @@ -24,7 +24,6 @@ our($opt_h); our($opt_l); our($opt_n); our($opt_p); -our($opt_s); our($opt_u); our($opt_c); @@ -35,7 +34,6 @@ Find small errors (nits) in documentation. Options: -d Detailed list of undocumented (implies -u) -l Print bogus links -n Print nits in POD pages - -s Also print missing sections in POD pages (implies -n) -p Warn if non-public name documented (implies -n) -u List undocumented functions -h Print this help message @@ -217,7 +215,6 @@ sub check() foreach ((@{$mandatory_sections{'*'}}, @{$mandatory_sections{$section}})) { # Skip "return values" if not -s - next if $_ eq 'RETURN VALUES' and not $opt_s; print "$id: missing $_ head1 section\n" if $contents !~ /^=head1\s+${_}\s*$/m; } @@ -374,7 +371,7 @@ sub collectnames { # then remove 'something'. Note that 'something' # may contain POD codes as well... (?:(?:[^\|]|<[^>]*>)*\|)? - # we're only interested in referenses that have + # we're only interested in references that have # a one digit section number ([^\/>\(]+\(\d\)) /gx; @@ -474,13 +471,13 @@ sub checkflags() { return $ok; } -getopts('cdlnsphu'); +getopts('cdlnphu'); &help() if $opt_h; -$opt_n = 1 if $opt_s or $opt_p; +$opt_n = 1 if $opt_p; $opt_u = 1 if $opt_d; -die "Need one of -[cdlnspu] flags.\n" +die "Need one of -[cdlnpu] flags.\n" unless $opt_c or $opt_l or $opt_n or $opt_u; if ( $opt_c ) {