[PATCH] fix unbound variable problem in runmirrors(Re: New mirror scripts for Debian mirrors)
>>>>> In <[🔎] 87d4h5g7tm.fsf@vorlon.ganneff.de>
>>>>> Joerg Jaspert <joerg@debian.org> wrote:
>> On 11563 March 1977, Panagiotis Christias wrote:
>>
>> > are you sure that the "set -u" should be used?
>>
>> Yep I am.
>>
>> > I get a lot of "VAR: unbound variable" messages and ftpsync aborts.
>>
>> Yes, about HOOK1 til HOOK5 and HUB.
>> My mistake, I put a version up that didn't have them defined in the
>> script itself, sorry.
>> If you redownload the tarball (or git pull), you will get a fixed
>> version.
I found same kind of problems in runmirrors.
(HOOK1,2,3 is not defined)
Signed-off-by: ISHIKAWA Mutsumi <ishikawa@hanzubon.jp>
---
bin/runmirrors | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/bin/runmirrors b/bin/runmirrors
index 9d31b59..19bdcb5 100755
--- a/bin/runmirrors
+++ b/bin/runmirrors
@@ -63,6 +63,11 @@ PUSHARCHIVE=${PUSHARCHIVE:-"${CONF}"}
# How long to wait for mirrors to do stage1 if we have multi-stage syncing
PUSHDELAY=${PUSHDELAY:-240}
+# Hooks
+HOOK1=${HOOK1:-""}
+HOOK2=${HOOK2:-""}
+HOOK3=${HOOK3:-""}
+
# Some sane defaults
cd ${BASEDIR}
umask 022
--
1.5.6.5
--
ISHIKAWA Mutsumi
<ishikawa@debian.org>, <ishikawa@hanzubon.jp>, <ishikawa@osdn.jp>
Reply to: