aboutsummaryrefslogtreecommitdiffstats
path: root/main/compat-pvgrub/update-pvgrub
diff options
context:
space:
mode:
authorJailBox <jailbox@tools.dk>2019-10-24 00:23:03 +0200
committerKevin Daudt <kdaudt@alpinelinux.org>2019-10-28 19:15:13 +0000
commitd07bbedd089b417e804674538b9be1d7c0a49be9 (patch)
tree3084ca9b5be6faf685c107687ed0cd0a31dc8a24 /main/compat-pvgrub/update-pvgrub
parent987f5b81589ec99758bebc6eeb6a58c06ddfee03 (diff)
downloadaports-d07bbedd089b417e804674538b9be1d7c0a49be9.tar.bz2
aports-d07bbedd089b417e804674538b9be1d7c0a49be9.tar.xz
main/compat-pvgrub: prevent output to wrong conf-file
if "$myconf" defines/redefines "$conf" the generated output would go to the wrong file I.e. >echo "conf=/boot/mybootdir/extlinux.conf" >> /etc/update-extliunx.conf /sbin/update-extlinux will honor this, while update-pvgrub would write to the wrong config file. So postpone presetting "$conf" until "$myconf" has been source'd
Diffstat (limited to 'main/compat-pvgrub/update-pvgrub')
-rwxr-xr-xmain/compat-pvgrub/update-pvgrub3
1 files changed, 2 insertions, 1 deletions
diff --git a/main/compat-pvgrub/update-pvgrub b/main/compat-pvgrub/update-pvgrub
index 7625d1d923..088aa21db9 100755
--- a/main/compat-pvgrub/update-pvgrub
+++ b/main/compat-pvgrub/update-pvgrub
@@ -5,7 +5,6 @@ default=0
timeout=5
verbose=0
-conf=/boot/grub/menu.lst
myconf=/etc/update-extlinux.conf
# read in extlinux settings
@@ -13,6 +12,8 @@ if [ -f "$myconf" ]; then
. $myconf
fi
+conf=/boot/grub/menu.lst
+
everbose() {
if [ "$verbose" = "0" ]; then
return