From df7ebf977a12ec6d988406af27e13547d53d62a7 Mon Sep 17 00:00:00 2001 From: Henry Asbridge Date: Sat, 19 Apr 2025 19:27:31 +0100 Subject: [PATCH] Handle long entitlements section in NPTicket 2.1 tickets (#1089) * Handle long entitlements section in NPTicket 2.1 tickets * Remove previous padding as it's no longer needed. * Add back one bit of padding as it was needed * Get Qodana to quit it's whining * More Qodana blugeoning --- .github/workflows/qodana_code_quality.yml | 2 ++ ProjectLighthouse/Tickets/Parser/TicketParser21.cs | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/qodana_code_quality.yml b/.github/workflows/qodana_code_quality.yml index e7b9e089..fdd4c7d5 100644 --- a/.github/workflows/qodana_code_quality.yml +++ b/.github/workflows/qodana_code_quality.yml @@ -16,6 +16,8 @@ jobs: contents: write pull-requests: write checks: write + security-events: write + actions: read steps: - uses: actions/checkout@v3 with: diff --git a/ProjectLighthouse/Tickets/Parser/TicketParser21.cs b/ProjectLighthouse/Tickets/Parser/TicketParser21.cs index 216372ef..585d7b52 100644 --- a/ProjectLighthouse/Tickets/Parser/TicketParser21.cs +++ b/ProjectLighthouse/Tickets/Parser/TicketParser21.cs @@ -29,8 +29,10 @@ public class TicketParser21 : ITicketParser this.reader.ReadTicketUInt32(); // status + SectionHeader entitlementsSection = this.reader.ReadSectionHeader(); // entitlements section + this.reader.SkipBytes(entitlementsSection.Length); + this.reader.ReadTicketEmpty(); // padding - this.reader.ReadTicketEmpty(); SectionHeader footer = this.reader.ReadSectionHeader(); // footer header if (footer.Type != SectionType.Footer)