mirror of
git://sourceware.org/git/newlib-cygwin.git
synced 2025-02-21 00:07:36 +08:00
* syscalls.cc (unlink_nt): Open native symlinks with
FILE_OPEN_REPARSE_POINT flag.
This commit is contained in:
parent
1c9b2968fa
commit
e563a4d5b8
@ -1,3 +1,8 @@
|
|||||||
|
2006-12-07 Corinna Vinschen <corinna@vinschen.de>
|
||||||
|
|
||||||
|
* syscalls.cc (unlink_nt): Open native symlinks with
|
||||||
|
FILE_OPEN_REPARSE_POINT flag.
|
||||||
|
|
||||||
2006-12-07 Corinna Vinschen <corinna@vinschen.de>
|
2006-12-07 Corinna Vinschen <corinna@vinschen.de>
|
||||||
|
|
||||||
* ntdll.h (STATUS_DELETE_PENDING): Define.
|
* ntdll.h (STATUS_DELETE_PENDING): Define.
|
||||||
|
@ -207,6 +207,10 @@ unlink_nt (path_conv &win32_name, bool setattrs)
|
|||||||
2K3 and in all cases, DeleteFile works, "delete on close" does not. */
|
2K3 and in all cases, DeleteFile works, "delete on close" does not. */
|
||||||
if (!win32_name.isremote ())
|
if (!win32_name.isremote ())
|
||||||
flags |= FILE_DELETE_ON_CLOSE;
|
flags |= FILE_DELETE_ON_CLOSE;
|
||||||
|
/* Add the reparse point flag to native symlinks, otherwise we remove the
|
||||||
|
target, not the symlink. */
|
||||||
|
if (win32_name.is_rep_symlink ())
|
||||||
|
flags |= FILE_OPEN_REPARSE_POINT;
|
||||||
|
|
||||||
win32_name.get_nt_native_path (upath);
|
win32_name.get_nt_native_path (upath);
|
||||||
InitializeObjectAttributes (&attr, &upath, OBJ_CASE_INSENSITIVE | OBJ_INHERIT,
|
InitializeObjectAttributes (&attr, &upath, OBJ_CASE_INSENSITIVE | OBJ_INHERIT,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user