diff options
-rw-r--r-- | quilt.changes | 1 | ||||
-rwxr-xr-x | scripts/rpatch.in | 12 |
2 files changed, 5 insertions, 8 deletions
diff --git a/quilt.changes b/quilt.changes index bc05f7a..ee85a09 100644 --- a/quilt.changes +++ b/quilt.changes @@ -5,6 +5,7 @@ Tue Nov 4 16:51:49 CET 2003 - agruen@suse.de - Fix the check for modified patches: That broke with the .pc file removal. - `quilt setup' sometimes forgot to create the patches sub-dir. +- Fix the timestamp check in scripts/rpatch.in for missing files. ------------------------------------------------------------------- Fri Oct 31 16:59:06 CET 2003 - agruen@suse.de diff --git a/scripts/rpatch.in b/scripts/rpatch.in index fd83e0d..eeb1363 100755 --- a/scripts/rpatch.in +++ b/scripts/rpatch.in @@ -28,22 +28,18 @@ files_may_have_changed() local patch=$1 file local patch_file=$(patch_file_name $patch) - local apply_t ts - apply_ts=$(date -r ".pc/$patch/.timestamp" '+%s') - if [ $? -ne 0 -o ! -e "$patch_file" -o ! -e ".pc/$patch/.timestamp" \ -o ".pc/$patch/.timestamp" -ot "$patch_file" ] then return 0 fi + local apply_ts=$(date -r ".pc/$patch/.timestamp" '+%s') ts for file in $(files_in_patch $patch) do - ts=$(date -r $file '+%s') 2> /dev/null - if [ $? -ne 0 -o "$ts" -gt $apply_ts ] - then - return 0 # file has changed - fi + ts=$(date -r $file '+%s' 2> /dev/null) + [ -z "$ts" ] && return 0 + [ "$ts" -gt $apply_ts ] && return 0 done return 1 } |