bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

poor mv error message


From: Eric Blake
Subject: poor mv error message
Date: Fri, 3 Aug 2007 14:45:53 +0000 (UTC)
User-agent: Loom/3.14 (http://gmane.org/)

We probably ought to make this error message smarter:

$ mkdir a
$ mv a/. b
mv: cannot move `a/.' to a subdirectory of itself, `b'

Huh?  ./b is not a subdirectory of ./a.  The problem is that rename(2)'s EINVAL 
has two distinct reasons for occuring, either subdirectory recursion (as was 
claimed in the above message), OR when either pathname matches the extended 
regex /(^|\/)\.\.?\/?$/ (as was what really happened).

-- 
Eric Blake






reply via email to

[Prev in Thread] Current Thread [Next in Thread]