checkpoint

This commit is contained in:
2020-04-29 23:47:06 -04:00
parent 64f7dd4b7d
commit 19a9fc06ba
31 changed files with 678 additions and 360 deletions

View File

@@ -4,13 +4,9 @@ using System.Runtime.InteropServices;
namespace Foodsoft.Alpm
{
internal class SafePackageHandle : SafeHandle
internal abstract class SafePackageHandle : SafeHandle
{
protected SafePackageHandle() : base(IntPtr.Zero, true) { }
[ReliabilityContract(Consistency.WillNotCorruptState, Cer.MayFail), PrePrepareMethod]
protected override bool ReleaseHandle() => alpm.alpm_pkg_free(handle) == 0;
public override bool IsInvalid
{
[ReliabilityContract(Consistency.WillNotCorruptState, Cer.Success), PrePrepareMethod]