Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ Persist() [1/5]

virtual void System.Security.AccessControl.ObjectSecurity< T >.Persist ( bool enableOwnershipPrivilege,
string name,
AccessControlSections includeSections )
inlineprotectedvirtual

Definition at line 264 of file ObjectSecurity.cs.

265 {
266 Privilege privilege = null;
267 try
268 {
269 if (enableOwnershipPrivilege)
270 {
271 privilege = new Privilege("SeTakeOwnershipPrivilege");
272 try
273 {
274 privilege.Enable();
275 }
276 catch (PrivilegeNotHeldException)
277 {
278 }
279 }
280 Persist(name, includeSections);
281 }
282 catch
283 {
284 privilege?.Revert();
285 throw;
286 }
287 finally
288 {
289 privilege?.Revert();
290 }
291 }
virtual void Persist(string name, AccessControlSections includeSections)

References System.Security.AccessControl.Privilege.Enable(), System.Security.AccessControl.ObjectSecurity< T >.Persist(), and System.Security.AccessControl.Privilege.Revert().