Skip to content

Commit 858d555

Browse files
committed
boot-qemu.py: Fix check in _prepare_initrd()
This should have been checking the existence of the file. This makes a future diff make a little more sense. Signed-off-by: Nathan Chancellor <nathan@kernel.org>
1 parent 8583db5 commit 858d555

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

boot-qemu.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ def _prepare_initrd(self):
164164
if not self._initrd_arch:
165165
raise RuntimeError('No initrd architecture specified?')
166166
if not (src := Path(BOOT_UTILS, 'images', self._initrd_arch,
167-
'rootfs.cpio.zst')):
167+
'rootfs.cpio.zst')).exists():
168168
raise FileNotFoundError(f"initrd ('{src}') does not exist?")
169169

170170
(dst := src.with_suffix('')).unlink(missing_ok=True)

0 commit comments

Comments
 (0)