We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 765ad0e commit 2c1b311Copy full SHA for 2c1b311
src/hotspot/share/utilities/copy.hpp
@@ -211,6 +211,7 @@ class Copy : AllStatic {
211
// byte_count is in bytes to check its alignment
212
assert_params_ok(from, to, HeapWordSize);
213
assert_byte_count_ok(byte_count, HeapWordSize);
214
+ if (byte_count == 0) return;
215
216
size_t count = align_up(byte_count, HeapWordSize) >> LogHeapWordSize;
217
assert(from <= to || to + count <= from, "do not overwrite source data");
0 commit comments