[Merge] ~jefferyto/ubuntu/+source/initramfs-tools:ubuntu-core-dev-fix-resume-device-type-check into ~ubuntu-core-dev/ubuntu/+source/initramfs-tools:ubuntu/devel
Benjamin Drung
mp+468643 at code.launchpad.net
Wed Jul 3 14:50:48 UTC 2024
Review: Needs Fixing
Response from util-linux upstream: we need to fix initramfs-tools.
Diff comments:
> diff --git a/hooks/resume b/hooks/resume
> index 8ff84dd..a13e5a2 100755
> --- a/hooks/resume
> +++ b/hooks/resume
> @@ -23,8 +23,9 @@ if [ -n "$RESUME" ] && [ "$RESUME" != auto ]; then
> if [ "$RESUME" = none ]; then
> exit 0
> fi
> - if resume_dev_node="$(resolve_device "$RESUME")" && \
> - blkid -p -n swap "$resume_dev_node" >/dev/null 2>&1; then
> + resume_dev_node=$(resolve_device "$RESUME")
moving it out of the if-condition changes the behavior in case resolve_device fails.
> + resume_dev_type=$(blkid -p -s TYPE -o value "$resume_dev_node")
> + if [ "$resume_dev_type" = swap ]; then
> exit 0
> fi
>
--
https://code.launchpad.net/~jefferyto/ubuntu/+source/initramfs-tools/+git/initramfs-tools/+merge/468643
Your team Ubuntu Core Development Team is subscribed to branch ~ubuntu-core-dev/ubuntu/+source/initramfs-tools:ubuntu/devel.
More information about the Ubuntu-reviews
mailing list