[PATCH 1/1] diff: the_same file checking fix
Denys Vlasenko
vda.linux at googlemail.com
Mon Apr 4 01:18:45 UTC 2011
On Monday 28 March 2011 08:50, Roman Borisov wrote:
> On 03/26/2011 02:10 AM, ext Matheus Izvekov wrote:
> > On Fri, Mar 25, 2011 at 6:31 AM, Roman Borisov
> > <ext-roman.borisov at nokia.com <mailto:ext-roman.borisov at nokia.com>> wrote:
> >
> > Fixed the bug with checking physically the same file; for example:
> > 'mount --bind parent parent/child' command makes 'parent' mount
> > point which
> > physically is 'parent/child';
> > If we are trying to 'diff parent parent/child' we must get '0' because
> > files (dirs) are physically the same;
> > That means we need to check stats of files and return '0' in this case.
>
>
> > What are you trying to accomplish here? Performance improvement?
>
> Hi,
>
> I'm trying to fix bug described above;
>
> mkdir parent
> mkdir parent/child
> mount --bind parent parent/child
> diff -r parent parent/child
>
> expected result is '0' because it is the same dir; but actually we got '1'
I think this is not a documented diff behavior :D
It is risky to use this feature.
--
vda
More information about the busybox
mailing list