src/os/bsd/vm/os_bsd.cpp

Print this page

        

*** 351,371 **** #endif // Base path of extensions installed on the system. #define SYS_EXT_DIR "/usr/java/packages" #define EXTENSIONS_DIR "/lib/ext" - #define ENDORSED_DIR "/lib/endorsed" #ifndef __APPLE__ // Buffer that fits several sprintfs. // Note that the space for the colon and the trailing null are provided // by the nulls included by the sizeof operator. const size_t bufsize = ! MAX3((size_t)MAXPATHLEN, // For dll_dir & friends. ! (size_t)MAXPATHLEN + sizeof(EXTENSIONS_DIR) + sizeof(SYS_EXT_DIR) + sizeof(EXTENSIONS_DIR), // extensions dir ! (size_t)MAXPATHLEN + sizeof(ENDORSED_DIR)); // endorsed dir char *buf = (char *)NEW_C_HEAP_ARRAY(char, bufsize, mtInternal); // sysclasspath, java_home, dll_dir { char *pslash; --- 351,369 ---- #endif // Base path of extensions installed on the system. #define SYS_EXT_DIR "/usr/java/packages" #define EXTENSIONS_DIR "/lib/ext" #ifndef __APPLE__ // Buffer that fits several sprintfs. // Note that the space for the colon and the trailing null are provided // by the nulls included by the sizeof operator. const size_t bufsize = ! MAX2((size_t)MAXPATHLEN, // For dll_dir & friends. ! (size_t)MAXPATHLEN + sizeof(EXTENSIONS_DIR) + sizeof(SYS_EXT_DIR) + sizeof(EXTENSIONS_DIR)); // extensions dir char *buf = (char *)NEW_C_HEAP_ARRAY(char, bufsize, mtInternal); // sysclasspath, java_home, dll_dir { char *pslash;
*** 423,436 **** // Extensions directories. sprintf(buf, "%s" EXTENSIONS_DIR ":" SYS_EXT_DIR EXTENSIONS_DIR, Arguments::get_java_home()); Arguments::set_ext_dirs(buf); - // Endorsed standards default directory. - sprintf(buf, "%s" ENDORSED_DIR, Arguments::get_java_home()); - Arguments::set_endorsed_dirs(buf); - FREE_C_HEAP_ARRAY(char, buf, mtInternal); #else // __APPLE__ #define SYS_EXTENSIONS_DIR "/Library/Java/Extensions" --- 421,430 ----
*** 443,455 **** // Buffer that fits several sprintfs. // Note that the space for the colon and the trailing null are provided // by the nulls included by the sizeof operator. const size_t bufsize = ! MAX3((size_t)MAXPATHLEN, // for dll_dir & friends. ! (size_t)MAXPATHLEN + sizeof(EXTENSIONS_DIR) + system_ext_size, // extensions dir ! (size_t)MAXPATHLEN + sizeof(ENDORSED_DIR)); // endorsed dir char *buf = (char *)NEW_C_HEAP_ARRAY(char, bufsize, mtInternal); // sysclasspath, java_home, dll_dir { char *pslash; --- 437,448 ---- // Buffer that fits several sprintfs. // Note that the space for the colon and the trailing null are provided // by the nulls included by the sizeof operator. const size_t bufsize = ! MAX2((size_t)MAXPATHLEN, // for dll_dir & friends. ! (size_t)MAXPATHLEN + sizeof(EXTENSIONS_DIR) + system_ext_size); // extensions dir char *buf = (char *)NEW_C_HEAP_ARRAY(char, bufsize, mtInternal); // sysclasspath, java_home, dll_dir { char *pslash;
*** 523,546 **** // than necessary is allocated). sprintf(buf, "%s" SYS_EXTENSIONS_DIR ":%s" EXTENSIONS_DIR ":" SYS_EXTENSIONS_DIRS, user_home_dir, Arguments::get_java_home()); Arguments::set_ext_dirs(buf); - // Endorsed standards default directory. - sprintf(buf, "%s" ENDORSED_DIR, Arguments::get_java_home()); - Arguments::set_endorsed_dirs(buf); - FREE_C_HEAP_ARRAY(char, buf, mtInternal); #undef SYS_EXTENSIONS_DIR #undef SYS_EXTENSIONS_DIRS #endif // __APPLE__ #undef SYS_EXT_DIR #undef EXTENSIONS_DIR - #undef ENDORSED_DIR } //////////////////////////////////////////////////////////////////////////////// // breakpoint support --- 516,534 ----
*** 2574,2583 **** --- 2562,2575 ---- size_t os::read(int fd, void *buf, unsigned int nBytes) { RESTARTABLE_RETURN_INT(::read(fd, buf, nBytes)); } + size_t os::read_at(int fd, void *buf, unsigned int nBytes, jlong offset) { + RESTARTABLE_RETURN_INT(::pread(fd, buf, nBytes, offset)); + } + void os::naked_short_sleep(jlong ms) { struct timespec req; assert(ms < 1000, "Un-interruptable sleep, short time use only"); req.tv_sec = 0;