src/share/vm/memory/allocation.cpp

changeset 2834
2a3da7eaf4a6
parent 2589
4a9604cd7c5f
child 3156
f08d439fab8c
     1.1 --- a/src/share/vm/memory/allocation.cpp	Tue Apr 12 14:18:53 2011 -0700
     1.2 +++ b/src/share/vm/memory/allocation.cpp	Wed Apr 27 09:09:57 2011 -0400
     1.3 @@ -44,6 +44,14 @@
     1.4    return (void *) AllocateHeap(size, "CHeapObj-new");
     1.5  }
     1.6  
     1.7 +void* CHeapObj::operator new (size_t size, const std::nothrow_t&  nothrow_constant) {
     1.8 +  char* p = (char*) os::malloc(size);
     1.9 +#ifdef ASSERT
    1.10 +  if (PrintMallocFree) trace_heap_malloc(size, "CHeapObj-new", p);
    1.11 +#endif
    1.12 +  return p;
    1.13 +}
    1.14 +
    1.15  void CHeapObj::operator delete(void* p){
    1.16   FreeHeap(p);
    1.17  }

mercurial