From: Ian Jackson Date: Sat, 5 Nov 2016 12:06:33 +0000 (+0000) Subject: cvs-adjustroot: silently succeed for */CVS/Root entries which already match the new... X-Git-Tag: archive/debian/5.0.0~9 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?a=commitdiff_plain;h=ada5f71103d960085dae68ebebc1a924ae48e1cd;p=chiark-utils.git cvs-adjustroot: silently succeed for */CVS/Root entries which already match the new value. Closes:#839708 (second half). Signed-off-by: Ian Jackson --- diff --git a/debian/changelog b/debian/changelog index aa22904..717e31d 100644 --- a/debian/changelog +++ b/debian/changelog @@ -5,6 +5,8 @@ chiark-utils (4.5.0~iwj5) unstable; urgency=medium * rebuild on current sid: Closes:#811216. * cvs-adjustroot: properly exit nonzero in case of error. Fixes the first half of #839708. + * cvs-adjustroot: silently succeed for */CVS/Root entries which + already match the new value. Closes:#839708 (second half). -- diff --git a/scripts/cvs-adjustroot b/scripts/cvs-adjustroot index 081859f..0448d9a 100755 --- a/scripts/cvs-adjustroot +++ b/scripts/cvs-adjustroot @@ -35,6 +35,7 @@ new="$1"; shift if $reinvoke; then filename="$1"; + if cmp -- "$filename" <(printf "%s\n" "$new"); then exit 0; fi cmp -- "$filename" <(printf "%s\n" "$old") printf "%s\n" "$new" >"$filename".new mv -f -- "$filename".new "$filename"