src/os/bsd/vm/os_bsd.cpp

Print this page




4664     *p = '\0';
4665   }
4666 
4667   // check xawt/libmawt.so
4668   strcpy(libmawtpath, buf);
4669   strcat(libmawtpath, xawtstr);
4670   if (::stat(libmawtpath, &statbuf) == 0) return false;
4671 
4672   // check libawt_xawt.so
4673   strcpy(libmawtpath, buf);
4674   strcat(libmawtpath, new_xawtstr);
4675   if (::stat(libmawtpath, &statbuf) == 0) return false;
4676 
4677   return true;
4678 #endif
4679 }
4680 
4681 // Get the default path to the core file
4682 // Returns the length of the string
4683 int os::get_core_path(char* buffer, size_t bufferSize) {
4684   int n = jio_snprintf(buffer, bufferSize, "/cores");
4685 
4686   // Truncate if theoretical string was longer than bufferSize
4687   n = MIN2(n, (int)bufferSize);
4688 
4689   return n;
4690 }
4691 
4692 #ifndef PRODUCT
4693 void TestReserveMemorySpecial_test() {
4694   // No tests available for this platform
4695 }
4696 #endif


4664     *p = '\0';
4665   }
4666 
4667   // check xawt/libmawt.so
4668   strcpy(libmawtpath, buf);
4669   strcat(libmawtpath, xawtstr);
4670   if (::stat(libmawtpath, &statbuf) == 0) return false;
4671 
4672   // check libawt_xawt.so
4673   strcpy(libmawtpath, buf);
4674   strcat(libmawtpath, new_xawtstr);
4675   if (::stat(libmawtpath, &statbuf) == 0) return false;
4676 
4677   return true;
4678 #endif
4679 }
4680 
4681 // Get the default path to the core file
4682 // Returns the length of the string
4683 int os::get_core_path(char* buffer, size_t bufferSize) {
4684   int n = jio_snprintf(buffer, bufferSize, "/cores/core.%d", current_process_id());
4685 
4686   // Truncate if theoretical string was longer than bufferSize
4687   n = MIN2(n, (int)bufferSize);
4688 
4689   return n;
4690 }
4691 
4692 #ifndef PRODUCT
4693 void TestReserveMemorySpecial_test() {
4694   // No tests available for this platform
4695 }
4696 #endif