From 671fe2ce0110c5ff0d85b48dc3a297c3f0d1a9d8 Mon Sep 17 00:00:00 2001 From: laokz Date: Mon, 28 Aug 2023 22:10:02 +0800 Subject: [PATCH] kpatch-build: fix missed parameter of verify_patch_files Verify_patch_files() use `lsdiff` to get patches' path and verify they are supported. To be consistent with apply_patches() which using `patch -p1`, `lsdiff` should use '--strip=1' paremeter. Close: #1357 Signed-off-by: Kai Zhang --- kpatch-build/kpatch-build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kpatch-build/kpatch-build b/kpatch-build/kpatch-build index d01a8d987..5e02faafc 100755 --- a/kpatch-build/kpatch-build +++ b/kpatch-build/kpatch-build @@ -119,7 +119,7 @@ verify_patch_files() { local ret=0 for patch in "${PATCH_LIST[@]}"; do - for path in $(lsdiff "$patch" 2>/dev/null); do + for path in $(lsdiff --strip=1 "$patch" 2>/dev/null); do dir=$(dirname "$path") ext="${path##*.}"