Fix reading in wrong order

This commit is contained in:
jvyden 2022-01-30 15:36:48 -05:00
commit 3e6a80cc32
No known key found for this signature in database
GPG key ID: 18BCF2BE0262B278

View file

@ -94,6 +94,13 @@ public class NPTicket
reader.ReadUInt16BE(); // Ticket length, we don't care about this
#if DEBUG
SectionHeader bodyHeader = reader.ReadSectionHeader();
Logger.Log($"bodyHeader.Type is {bodyHeader.Type}", LoggerLevelLogin.Instance);
#else
reader.ReadSectionHeader();
#endif
switch (npTicket.ticketVersion)
{
case "2.1":
@ -105,13 +112,6 @@ public class NPTicket
default: throw new NotImplementedException();
}
#if DEBUG
SectionHeader bodyHeader = reader.ReadSectionHeader();
Logger.Log($"bodyHeader.Type is {bodyHeader.Type}", LoggerLevelLogin.Instance);
#else
reader.ReadSectionHeader();
#endif
if (npTicket.Platform == Platform.Unknown)
{
Logger.Log($"Could not determine platform from IssuerId {npTicket.IssuerId} decimal", LoggerLevelLogin.Instance);