Fall back on SetNamedSecurityInfo if SetFileSecurity fails in acl_set_file.
authorFabrice Popineau <fabrice.popineau@supelec.fr>
Tue, 31 Dec 2013 15:00:43 +0000 (17:00 +0200)
committerEli Zaretskii <eliz@gnu.org>
Tue, 31 Dec 2013 15:00:43 +0000 (17:00 +0200)
commit0bbd0e0b1d5f358c85506dcc5451e14fb95864a8
tree0a56bb067ef4682c3b634bc9d4ff9e2b558d728c
parent9b3c0a162e7876bab09c299ff4d803b632bf3ac8
Fall back on SetNamedSecurityInfo if SetFileSecurity fails in acl_set_file.

 src/w32.c (set_named_security_info): New function.
 (acl_set_file): Fall back on set_named_security_info if
 set_file_security fails.  Fixes rare failures in backups.
 (g_b_init_set_named_security_info_w)
 (g_b_init_set_named_security_info_a): New static variables.
 (globals_of_w32): Initialize them to zero.
 (set_named_security_info): Set them to non-zero if the
 corresponding API is available.
 (SetNamedSecurityInfoW_Proc, SetNamedSecurityInfoA_Proc): New
 function typedefs.
src/ChangeLog
src/w32.c