src/hotspot/share/memory/universe.cpp
changeset 59249 29b0d0b61615
parent 59070 22ee476cc664
child 59251 4cbfa5077d68
--- a/src/hotspot/share/memory/universe.cpp	Mon Nov 25 12:30:24 2019 +0100
+++ b/src/hotspot/share/memory/universe.cpp	Mon Nov 25 12:31:39 2019 +0100
@@ -580,7 +580,7 @@
   int next;
   if ((_preallocated_out_of_memory_error_avail_count > 0) &&
       SystemDictionary::Throwable_klass()->is_initialized()) {
-    next = (int)Atomic::add(-1, &_preallocated_out_of_memory_error_avail_count);
+    next = (int)Atomic::add(&_preallocated_out_of_memory_error_avail_count, -1);
     assert(next < (int)PreallocatedOutOfMemoryErrorCount, "avail count is corrupt");
   } else {
     next = -1;