Skip to content

Commit ed3377c

Browse files
author
Kevin Smith
committed
Fix assertion in ArrayBuffer slice
1 parent 9240377 commit ed3377c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/Runtime/Library/ArrayBuffer.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -560,7 +560,7 @@ namespace Js
560560
// start and end are clamped to valid indices, so the new length also cannot exceed MaxArrayBufferLength.
561561
// Therefore, should be safe to cast down newLen to uint32.
562562
// TODO: If we ever support allocating ArrayBuffer with byteLength > MaxArrayBufferLength we may need to review this math.
563-
Assert(newLen < MaxArrayBufferLength);
563+
Assert(newLen <= MaxArrayBufferLength);
564564
uint32 byteLength = static_cast<uint32>(newLen);
565565

566566
ArrayBuffer* newBuffer = nullptr;

0 commit comments

Comments
 (0)