strcpy (temp, map_w32_filename (oldname, NULL));
+ /* 'rename' (which calls MoveFileW) renames the _target_ of the
+ symlink, which is different from Posix behavior and not what we
+ want here. So in that case we pretend this is a cross-device move,
+ for which Frename_file already has a workaround. */
+ if (is_symlink (temp))
+ {
+ errno = EXDEV;
+ return -1;
+ }
/* volume_info is set indirectly by map_w32_filename. */
oldname_dev = volume_info.serialnum;