base-files: sysupgrade stage2: fix losetup detection
authorDaniel Golle <daniel@makrotopia.org>
Mon, 2 Aug 2021 18:51:58 +0000 (20:51 +0200)
committerDaniel Golle <daniel@makrotopia.org>
Tue, 3 Aug 2021 17:28:44 +0000 (18:28 +0100)
commitaf76e26b557270307e05be168c3b9463886306f1
tree0f1fc7d5148a14072c039c59f6cc8acba0beb6ff
parent022d1fe80f0bda01cbda62f29ee6f58b8dc0ae37
base-files: sysupgrade stage2: fix losetup detection

If the busybox applet losetup was selected, `command -v` selects that
during sysupgrade. As this applet is in another path and doesn't cover
the '-D' option which is used to make sure user-defined loop devices
are no longer active during sysupgrade.
Detect losetup at the path of the full utility to avoid error messages
in case of the busybox applet being selected.

Reported-by: fda77 <fda77@users.noreply.github.com>
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
package/base-files/files/lib/upgrade/stage2