fix bogus copy in Blast.cs

This commit is contained in:
Chris Forbes
2011-05-04 14:28:06 +12:00
parent 068ee3320e
commit 8aa206ef95

View File

@@ -123,7 +123,12 @@ namespace OpenRA.FileFormats
len -= copy; len -= copy;
next += (ushort)copy; next += (ushort)copy;
Array.Copy(outBuffer, source, outBuffer, dest, copy);
// copy with old-fashioned memcpy semantics
// in case of overlapping ranges. this is NOT
// the same as Array.Copy()
while( copy-- > 0 )
outBuffer[dest++] = outBuffer[source++];
// Flush window to outstream // Flush window to outstream
if (next == MAXWIN) if (next == MAXWIN)