fix erroneous GetData length warning

cosmonaut 2023-09-19 13:40:48 -07:00
parent b026b9e81f
commit 402c26131d
1 changed files with 1 additions and 1 deletions

View File

@ -74,7 +74,7 @@ namespace MoonWorks.Graphics
Logger.LogWarn("Requested too many bytes from buffer!");
}
if (dataLengthInBytes > data.Length)
if (dataLengthInBytes > data.Length * Marshal.SizeOf<T>())
{
Logger.LogWarn("Data length is larger than the provided Span!");
}