martin f krafft <[EMAIL PROTECTED]> wrote:

> Package: coreutils
> Version: 5.97-3
> Severity: minor
> File: /bin/mv
> Tags: upstream
>
> lapse:/tmp/cdt.d.G14944> mkdir -p foo/bar/a bar/b                        
> #[314]
> lapse:/tmp/cdt.d.G14944> mv foo/bar .                                    
> #[315]
> mv: cannot move `foo/bar' to a subdirectory of itself, `./bar'
>
> Huh? Sure, I am trying to overwrite bar, which would fail anyway,
> but I am not moving foo/bar to a subdirectory of itself...

Thanks for the report.
I doubt this is worth changing on coreutils' stable branch.
In coreutils-6.0, I get this:

  mv: cannot move `foo/bar' to `./bar': Directory not empty

because the attempted rename fails:

  rename("foo/bar", "./bar")              = -1 ENOTEMPTY (Directory not empty)

That diagnostic makes sense if you know that the
rename would have succeeded if ./bar had been empty.


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to