diff --git a/BurnOutSharp.Builder/Extensions.cs b/BurnOutSharp.Builder/Extensions.cs index b1436181..f05b359c 100644 --- a/BurnOutSharp.Builder/Extensions.cs +++ b/BurnOutSharp.Builder/Extensions.cs @@ -25,7 +25,7 @@ namespace BurnOutSharp.Builder public static byte[] ReadBytes(this byte[] content, ref int offset, int count) { // If there's an invalid byte count, don't do anything - if (count == 0) + if (count <= 0) return null; byte[] buffer = new byte[count]; @@ -163,7 +163,7 @@ namespace BurnOutSharp.Builder public static byte[] ReadBytes(this Stream stream, int count) { // If there's an invalid byte count, don't do anything - if (count == 0) + if (count <= 0) return null; byte[] buffer = new byte[count];