You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
#rnx #rb jonathan.adamczewski #preflight 625d7777d4124345879a84a7 #preflight 625d89af6813aa38e3cff392 [CL 19786950 by Tim Smith in ue5-main branch]
31 lines
1.0 KiB
C#
31 lines
1.0 KiB
C#
// Copyright (c) Microsoft. All rights reserved.
|
|
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
|
|
|
using Microsoft.Win32.SafeHandles;
|
|
|
|
namespace Microsoft.Build.Shared.FileSystem
|
|
{
|
|
/// <summary>
|
|
/// Handle for a volume iteration as returned by WindowsNative.FindFirstVolumeW />
|
|
/// </summary>
|
|
//EPIC BEGIN
|
|
[System.Diagnostics.CodeAnalysis.SuppressMessage("Interoperability", "CA1419:Provide a parameterless constructor that is as visible as the containing type for concrete types derived from 'System.Runtime.InteropServices.SafeHandle'", Justification = "<Pending>")]
|
|
//EPIC END
|
|
internal sealed class SafeFindFileHandle : SafeHandleZeroOrMinusOneIsInvalid
|
|
{
|
|
/// <summary>
|
|
/// Private constructor for the PInvoke marshaller.
|
|
/// </summary>
|
|
private SafeFindFileHandle()
|
|
: base(ownsHandle: true)
|
|
{
|
|
}
|
|
|
|
/// <nodoc/>
|
|
protected override bool ReleaseHandle()
|
|
{
|
|
return WindowsNative.FindClose(handle);
|
|
}
|
|
}
|
|
}
|