summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Gruenbacher <agruen@suse.de>2003-02-02 20:54:20 +0000
committerAndreas Gruenbacher <agruen@suse.de>2003-02-02 20:54:20 +0000
commit520289ad14262c163ebd50c38a730a0fdb8b604d (patch)
treecbd6589eeb121a491bc1b01542bbf1978ab94d43
parent79c783641c207378b874af9654e510a8594fb930 (diff)
downloadquilt-520289ad14262c163ebd50c38a730a0fdb8b604d.tar.gz
Still another bug in quilt patches
-rw-r--r--quilt/patches.in20
1 files changed, 12 insertions, 8 deletions
diff --git a/quilt/patches.in b/quilt/patches.in
index 413ff67..88a1f0c 100644
--- a/quilt/patches.in
+++ b/quilt/patches.in
@@ -43,11 +43,6 @@ scan_patches()
shift 2
local patch
- if [ $# -eq 0 ]
- then
- return 0
- fi
-
for patch in $(modified_files $file -- "$@" \
| cut -d $'\t' -f2)
do
@@ -97,9 +92,18 @@ fi
if [ -n "$opt_verbose" ]
then
top=$(top_patch)
- scan_patches "+ " $opt_file $(patches_before $top)
- scan_patches "= " $opt_file $top
- scan_patches " " $opt_file $(patches_after $top)
+ if [ -n "$top" ]
+ then
+ patches_before="$(patches_before $top)"
+ [ -n "$patches_before" ] &&
+ scan_patches "+ " $opt_file $patches_before
+ scan_patches "= " $opt_file $top
+ patches_after="$(patches_after $top)"
+ [ -n "$patches_after" ] &&
+ scan_patches " " $opt_file $(patches_after $top)
+ else
+ scan_patches " " $opt_file
+ fi
else
scan_patches "" $opt_file
fi