diff --git a/src/BizHawk.Client.EmuHawk/tools/HexEditor/HexEditor.cs b/src/BizHawk.Client.EmuHawk/tools/HexEditor/HexEditor.cs index 88617a1dc9..90bd2cc832 100644 --- a/src/BizHawk.Client.EmuHawk/tools/HexEditor/HexEditor.cs +++ b/src/BizHawk.Client.EmuHawk/tools/HexEditor/HexEditor.cs @@ -554,10 +554,13 @@ namespace BizHawk.Client.EmuHawk end = Math.Min(end, _domain.Size); end &= -(long)dataSize; - var range = new MutableRange(start, end - 1); - var dict = new Dictionary(); + if (end <= start) + return dict; + + var range = new MutableRange(start, end - 1); + switch (dataSize) { default: