代码拉取完成,页面将自动刷新
同步操作将从 src-anolis-os/grub2 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Andy Lutomirski <luto@kernel.org>
Date: Sun, 11 Jun 2017 19:17:40 -0400
Subject: [PATCH] Fix grub-setpassword -o's output path
The output path is set up in the command line parsing, but completely ignored
in the code that actually writes the files. This patch fixes that.
Signed-off-by: Peter Jones <pjones@redhat.com>
---
util/grub-setpassword.in | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/util/grub-setpassword.in b/util/grub-setpassword.in
index cf70257ee..5ebf50576 100644
--- a/util/grub-setpassword.in
+++ b/util/grub-setpassword.in
@@ -118,11 +118,11 @@ fi
# on the ESP, these will fail to set the permissions, but it's okay because
# the directory is protected.
-install -m 0600 /dev/null "${grubdir}/user.cfg" 2>/dev/null || :
-chmod 0600 "${grubdir}/user.cfg" 2>/dev/null || :
-echo "GRUB2_PASSWORD=${MYPASS}" > "${grubdir}/user.cfg"
+install -m 0600 /dev/null "${OUTPUT_PATH}/user.cfg" 2>/dev/null || :
+chmod 0600 "${OUTPUT_PATH}/user.cfg" 2>/dev/null || :
+echo "GRUB2_PASSWORD=${MYPASS}" > "${OUTPUT_PATH}/user.cfg"
-if ! grep -q "^### BEGIN /etc/grub.d/01_users ###$" "${grubdir}/grub.cfg"; then
+if ! grep -q "^### BEGIN /etc/grub.d/01_users ###$" "${OUTPUT_PATH}/grub.cfg"; then
echo "WARNING: The current configuration lacks password support!"
echo "Update your configuration with @grub_mkconfig@ to support this feature."
fi
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。