16 lines
461 B
C#
16 lines
461 B
C#
using System;
|
|
using System.Runtime.ConstrainedExecution;
|
|
using System.Runtime.InteropServices;
|
|
|
|
namespace Foodsoft.Alpm
|
|
{
|
|
internal abstract class SafePackageHandle : SafeHandle
|
|
{
|
|
protected SafePackageHandle() : base(IntPtr.Zero, true) { }
|
|
public override bool IsInvalid
|
|
{
|
|
[ReliabilityContract(Consistency.WillNotCorruptState, Cer.Success), PrePrepareMethod]
|
|
get => handle == IntPtr.Zero;
|
|
}
|
|
}
|
|
} |