summaryrefslogtreecommitdiff
path: root/tests/src/GC
diff options
context:
space:
mode:
authorJan Kotas <jkotas@microsoft.com>2015-11-17 14:24:22 -0800
committerJan Kotas <jkotas@microsoft.com>2015-11-17 14:24:22 -0800
commita2bd4c042f22210fb6257c662cddeb601512908b (patch)
treebe03108a9f6818e61fd3518b22c80e5085bd0679 /tests/src/GC
parent82c0d541fdbf5d82567d0091b80563cf6b65fc7e (diff)
parent6bab1bfc3cd23bf71ed6375ca8d60567d56df286 (diff)
downloadcoreclr-a2bd4c042f22210fb6257c662cddeb601512908b.tar.gz
coreclr-a2bd4c042f22210fb6257c662cddeb601512908b.tar.bz2
coreclr-a2bd4c042f22210fb6257c662cddeb601512908b.zip
Merge pull request #2067 from akoeplinger/fix-overflow-gcstress
Fix OverflowException in b115557.cs GC test on systems with fewer than four processors/cores
Diffstat (limited to 'tests/src/GC')
-rw-r--r--tests/src/GC/Stress/Tests/b115557.cs2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/src/GC/Stress/Tests/b115557.cs b/tests/src/GC/Stress/Tests/b115557.cs
index 39cc4e84a7..7a02d51ad1 100644
--- a/tests/src/GC/Stress/Tests/b115557.cs
+++ b/tests/src/GC/Stress/Tests/b115557.cs
@@ -28,7 +28,7 @@ internal class MyThread
for (int i = 0; i < _allocPerThreadMB / 2; i++)
{
largeArray[i] = new byte[2 * 1024 * 1024]; // 2 MB
- largeArray[i][i + 100] = Convert.ToByte(i);
+ largeArray[i][i + 100] = Convert.ToByte(Math.Min(i, byte.MaxValue));
}
int sum = 0;
for (int i = 0; i < _allocPerThreadMB / 2; i++)