* path.cc (symlink_worker): Return EEXIST if newpath exists.

This commit is contained in:
Corinna Vinschen 2006-07-19 08:20:26 +00:00
parent 3438293a0b
commit ef4954b62d
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,7 @@
2006-07-19 Corinna Vinschen <corinna@vinschen.de>
* path.cc (symlink_worker): Return EEXIST if newpath exists.
2006-07-18 Christopher Faylor <cgf@timesys.com>
* tty.cc (tty_list::terminate): Don't enter the busy loop if we don't

View File

@ -2757,7 +2757,8 @@ symlink_worker (const char *oldpath, const char *newpath, bool use_winsym,
syscall_printf ("symlink (%s, %s)", oldpath, win32_path.get_win32 ());
if (win32_path.is_auto_device ())
if ((!isdevice && win32_path.exists ())
|| win32_path.is_auto_device ())
{
set_errno (EEXIST);
goto done;