mirror of
https://github.com/aaru-dps/Aaru.git
synced 2025-12-16 19:24:25 +00:00
General cleanup and refactor.
This commit is contained in:
@@ -30,20 +30,20 @@
|
||||
// Copyright © 2011-2022 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
namespace Aaru.DiscImages;
|
||||
|
||||
using System;
|
||||
using System.IO;
|
||||
using Aaru.CommonTypes.Interfaces;
|
||||
using Aaru.Console;
|
||||
|
||||
namespace Aaru.DiscImages;
|
||||
|
||||
public sealed partial class TeleDisk
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public bool Identify(IFilter imageFilter)
|
||||
{
|
||||
_header = new Header();
|
||||
byte[] headerBytes = new byte[12];
|
||||
var headerBytes = new byte[12];
|
||||
Stream stream = imageFilter.GetDataForkStream();
|
||||
stream.Seek(0, SeekOrigin.Begin);
|
||||
|
||||
@@ -65,7 +65,7 @@ public sealed partial class TeleDisk
|
||||
_header.Sides = headerBytes[9];
|
||||
_header.Crc = BitConverter.ToUInt16(headerBytes, 10);
|
||||
|
||||
byte[] headerBytesForCrc = new byte[10];
|
||||
var headerBytesForCrc = new byte[10];
|
||||
Array.Copy(headerBytes, headerBytesForCrc, 10);
|
||||
ushort calculatedHeaderCrc = TeleDiskCrc(0x0000, headerBytesForCrc);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user