rename: fix Solaris 10 bug
authorEric Blake <ebb9@byu.net>
Thu, 1 Oct 2009 03:57:58 +0000 (21:57 -0600)
committerEric Blake <ebb9@byu.net>
Fri, 2 Oct 2009 12:07:23 +0000 (06:07 -0600)
commit2f45acc353ef4116714ea582434c7a8318e3e486
tree42b5dd47dba33fe8a4b2b7a1bdda04a9695595bd
parentadd9fba5e1e248ac77e6abe31749a10cd2672d77
rename: fix Solaris 10 bug

rename("file","name/") mistakenly succeeded.  But since Solaris 10
already obeys POSIX behavior on rename("link/","name"), we avoid
blindly forcing GNU behavior of rejecting symlinks with trailing slash.

* m4/rename.m4 (gl_FUNC_RENAME): Detect Solaris bug.
* lib/rename.c (rpl_rename): Don't cripple POSIX behavior if this
was the only bug.

Signed-off-by: Eric Blake <ebb9@byu.net>
ChangeLog
lib/rename.c
m4/rename.m4