Sorry for a mistake. Please see the comments inline below.
On Wed, May 24, 2023 at 9:21 PM Pingfan Liu <piliu(a)redhat.com> wrote:
After introducing 64k variant kernel on aarch64, an example kernel name
looks like "vmlinuz-5.14.0-316.el9.aarch64+64k". To match the plus
symbol, it demands an escape charater.
Signed-off-by: Pingfan Liu <piliu(a)redhat.com>
---
kdumpctl | 2 ++
1 file changed, 2 insertions(+)
diff --git a/kdumpctl b/kdumpctl
index 20ed7bf..5c55a6a 100755
--- a/kdumpctl
+++ b/kdumpctl
@@ -1406,6 +1406,8 @@ _filter_grubby_kernel_str()
_find_kernel_path_by_release()
{
local _release="$1" _grubby_kernel_str _kernel_path
+
+ _release=$(echo "$_release" | sed 's/+/\+/g')
^^^should be 's/+/\\+/g'
Which can escape the backslash
Thanks,
Pingfan
_grubby_kernel_str=$(grubby --info ALL | grep -E
"^kernel=.*$_release(\/\w+)?\"$")
_kernel_path=$(_filter_grubby_kernel_str "$_grubby_kernel_str")
if [[ -z $_kernel_path ]]; then
--
2.31.1
_______________________________________________
kexec mailing list -- kexec(a)lists.fedoraproject.org
To unsubscribe send an email to kexec-leave(a)lists.fedoraproject.org
Fedora Code of Conduct:
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines:
https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives:
https://lists.fedoraproject.org/archives/list/kexec@lists.fedoraproject.org
Do not reply to spam, report it:
https://pagure.io/fedora-infrastructure/new_issue