Bug 2558

Summary: gendiff gets confused by SUFFIX in the upmost directory name
Product: Sisyphus Reporter: imz <vanyaz>
Component: rpm-buildAssignee: placeholder <placeholder>
Status: CLOSED FIXED QA Contact: qa-sisyphus
Severity: minor    
Priority: P5 CC: arseny, glebfm, imz, ldv, placeholder, vt
Version: unstable   
Hardware: all   
OS: Linux   

Description imz 2003-05-04 00:51:28 MSD
gendiff d.SUFFIX .SUFFIX

called in a directory where both

d.SUFFIX
d

exist, doesn\'t not produce the expected. I expect the output not to depend on the contents of d, but the output includes the difference between d and d.SUFFIX.

---

---
rpm-build-4.0.4-alt16

To fight this, I suggest the enhancement:

--- /usr/bin/gendiff    2003-05-04 00:48:31 +0400
+++ /usr/bin/gendiff.depth0     2003-05-04 00:41:38 +0400
@@ -11,7 +11,7 @@
 
 [ -z \&quot;$3\&quot; ] || echo &gt;\&quot;$RPM/SOURCES/$1-$3.patch\&quot;
 
-find \&quot;$1\&quot; -mindepth 1 \\( -name \&quot;*$2\&quot; -o -name \&quot;.*$2\&quot; \\) -print |
+find \&quot;$1\&quot; \\( -name \&quot;*$2\&quot; -o -name \&quot;.*$2\&quot; \\) -print |
 while read fin; do
        fou=`echo \&quot;$fin\&quot; |sed -e \&quot;s/$2\\$//\&quot;`;
        [ -r \&quot;$fin\&quot; ] || fin=\&quot;/dev/null\&quot;

Comment 1 Dmitry V. Levin 2003-09-27 21:52:58 MSD
Fixed in rpm-build-4.0.4-alt26