From 1b81ececd372dd2f4b6ad4df45961a1f18315b75 Mon Sep 17 00:00:00 2001
From: "Ryan C. Gordon" <[EMAIL REDACTED]>
Date: Tue, 21 Mar 2023 21:56:34 -0700
Subject: [PATCH] wikiheaders.pl: Fixed uninitialized value warning when run
without arguments.
---
build-scripts/wikiheaders.pl | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/build-scripts/wikiheaders.pl b/build-scripts/wikiheaders.pl
index 4633ef1d6a97..1049e145e754 100755
--- a/build-scripts/wikiheaders.pl
+++ b/build-scripts/wikiheaders.pl
@@ -59,10 +59,6 @@
$optionsfname = $default_optionsfname;
}
-if (not defined $manpath) {
- $manpath = "$srcpath/man";
-}
-
if (defined $optionsfname) {
open OPTIONS, '<', $optionsfname or die("Failed to open options file '$optionsfname': $!\n");
while (<OPTIONS>) {
@@ -490,6 +486,10 @@ sub usage {
usage() if not defined $wikipath;
#usage() if $copy_direction == 0;
+if (not defined $manpath) {
+ $manpath = "$srcpath/man";
+}
+
my @standard_wiki_sections = (
'Draft',
'[Brief]',