src/os_cpu/linux_x86/vm/os_linux_x86.cpp

changeset 4763
9ef47379df20
parent 4710
9058789475af
child 4993
746b070f5022
equal deleted inserted replaced
4762:0a2deac0bbfb 4763:9ef47379df20
338 } else if (sig == SIGBUS /* && info->si_code == BUS_OBJERR */) { 338 } else if (sig == SIGBUS /* && info->si_code == BUS_OBJERR */) {
339 // BugId 4454115: A read from a MappedByteBuffer can fault 339 // BugId 4454115: A read from a MappedByteBuffer can fault
340 // here if the underlying file has been truncated. 340 // here if the underlying file has been truncated.
341 // Do not crash the VM in such a case. 341 // Do not crash the VM in such a case.
342 CodeBlob* cb = CodeCache::find_blob_unsafe(pc); 342 CodeBlob* cb = CodeCache::find_blob_unsafe(pc);
343 nmethod* nm = cb->is_nmethod() ? (nmethod*)cb : NULL; 343 nmethod* nm = (cb != NULL && cb->is_nmethod()) ? (nmethod*)cb : NULL;
344 if (nm != NULL && nm->has_unsafe_access()) { 344 if (nm != NULL && nm->has_unsafe_access()) {
345 stub = StubRoutines::handler_for_unsafe_access(); 345 stub = StubRoutines::handler_for_unsafe_access();
346 } 346 }
347 } 347 }
348 else 348 else

mercurial