Lines Matching refs:buf
785 char buf[MAXPATHLEN];
786 os::jvm_path(buf, sizeof(buf));
790 *(strrchr(buf, '/')) = '\0'; /* get rid of /libjvm.so */
791 pslash = strrchr(buf, '/');
794 dll_path = malloc(strlen(buf) + 1);
797 strcpy(dll_path, buf);
801 pslash = strrchr(buf, '/');
804 pslash = strrchr(buf, '/');
810 home_path = malloc(strlen(buf) + 1);
813 strcpy(home_path, buf);
959 char *buf = (char *) malloc(strlen(Arguments::get_java_home()) +
962 sprintf(buf, "%s" EXTENSIONS_DIR ":" COMMON_DIR EXTENSIONS_DIR,
964 Arguments::set_ext_dirs(buf);
969 char * buf = malloc(strlen(Arguments::get_java_home()) + sizeof(ENDORSED_DIR));
970 sprintf(buf, "%s" ENDORSED_DIR, Arguments::get_java_home());
971 Arguments::set_endorsed_dirs(buf);
1823 char * os::local_time_string(char *buf, size_t buflen) {
1828 jio_snprintf(buf, buflen, "%d-%02d-%02d %02d:%02d:%02d",
1831 return buf;
1864 char buf[16];
1865 jio_snprintf(buf, sizeof(buf), UINTX_FORMAT, os::current_thread_id());
1866 out.print_raw_cr(buf);
1938 const char* os::get_current_directory(char *buf, int buflen) {
1939 return getcwd(buf, buflen);
1963 bool os::dll_address_to_function_name(address addr, char *buf,
1986 if (buf != NULL) {
1987 if (!Decoder::demangle(dlinfo.dli_sname, buf, buflen))
1988 jio_snprintf(buf, buflen, "%s", dlinfo.dli_sname);
1996 buf, buflen, offset, dlinfo.dli_fname)) {
2000 if (buf != NULL) buf[0] = '\0';
2006 if (buf != NULL) {
2007 if (!Decoder::demangle(dlinfo.dli_sname, buf, buflen))
2008 jio_snprintf(buf, buflen, dlinfo.dli_sname);
2014 buf, buflen, offset, dlinfo.dli_fname)) {
2018 if (buf != NULL) buf[0] = '\0';
2024 bool os::dll_address_to_library_name(address addr, char* buf,
2029 if (buf) jio_snprintf(buf, buflen, "%s", dlinfo.dli_fname);
2033 if (buf) buf[0] = '\0';
2231 char buf[32];
2233 while ((bytes = ::read(fd, buf, sizeof(buf))) > 0) {
2234 st->print_raw(buf, bytes);
2334 char buf[buflen];
2336 st->print("si_signo=%s: ", os::exception_name(si->si_signo, buf, buflen));
2401 char* buf, int buflen) {
2403 bool found = os::dll_address_to_library_name(handler, buf, buflen, &offset);
2407 p1 = buf;
2410 jio_snprintf(buf, buflen, "%s+0x%x", p1, offset);
2412 jio_snprintf(buf, buflen, PTR_FORMAT, handler);
2414 return buf;
2418 char* buf, size_t buflen) {
2423 st->print("%s: ", os::exception_name(sig, buf, buflen));
2434 st->print("[%s]", get_signal_handler_name(handler, buf, buflen));
2462 void os::print_signal_handlers(outputStream* st, char* buf, size_t buflen) {
2464 print_signal_handler(st, SIGSEGV, buf, buflen);
2465 print_signal_handler(st, SIGBUS , buf, buflen);
2466 print_signal_handler(st, SIGFPE , buf, buflen);
2467 print_signal_handler(st, SIGPIPE, buf, buflen);
2468 print_signal_handler(st, SIGXFSZ, buf, buflen);
2469 print_signal_handler(st, SIGILL , buf, buflen);
2470 print_signal_handler(st, INTERRUPT_SIGNAL, buf, buflen);
2471 print_signal_handler(st, ASYNC_SIGNAL, buf, buflen);
2472 print_signal_handler(st, BREAK_SIGNAL, buf, buflen);
2473 print_signal_handler(st, SHUTDOWN1_SIGNAL , buf, buflen);
2474 print_signal_handler(st, SHUTDOWN2_SIGNAL , buf, buflen);
2475 print_signal_handler(st, SHUTDOWN3_SIGNAL, buf, buflen);
2476 print_signal_handler(st, os::Solaris::SIGinterrupt(), buf, buflen);
2477 print_signal_handler(st, os::Solaris::SIGasync(), buf, buflen);
2483 void os::jvm_path(char *buf, jint buflen) {
2487 buf[0] = '\0';
2492 strcpy(buf, saved_jvm_path);
2499 realpath((char *)dlinfo.dli_fname, buf);
2502 // Support for the gamma launcher. Typical value for buf is
2508 const char *p = buf + strlen(buf) - 1;
2509 for (int count = 0; p > buf && count < 5; ++count) {
2510 for (--p; p > buf && *p != '/'; --p)
2531 p = strrchr(buf, '/');
2535 realpath(java_home_var, buf);
2538 len = strlen(buf);
2539 jrelib_p = buf + len;
2541 if (0 != access(buf, F_OK)) {
2545 if (0 == access(buf, F_OK)) {
2549 len = strlen(buf);
2550 snprintf(buf + len, buflen-len, "/hotspot/libjvm%s.so", p);
2553 realpath((char *)dlinfo.dli_fname, buf);
2559 strcpy(saved_jvm_path, buf);
2575 size_t os::lasterror(char *buf, size_t len) {
2584 ::strncpy(buf, s, n);
2585 buf[n] = '\0';
3213 char buf[256];
3214 buf[0] = '\0';
3216 jio_snprintf(buf, sizeof(buf), ": %s", strerror(err));
3220 "%s", bytes, requested_addr, addr, buf);
3647 size_t os::read(int fd, void *buf, unsigned int nBytes) {
3648 INTERRUPTIBLE_RETURN_INT_VM(::read(fd, buf, nBytes), os::Solaris::clear_interrupted);
3651 size_t os::restartable_read(int fd, void *buf, unsigned int nBytes) {
3652 INTERRUPTIBLE_RETURN_INT(::read(fd, buf, nBytes), os::Solaris::clear_interrupted);
4456 char buf[16];
4458 while (::read(0, buf, sizeof(buf)) <= 0) { ::sleep(100); }
4460 return buf[0] == 'y' || buf[0] == 'Y';
4840 char buf[O_BUFLEN];
4890 tty->print("Warning: %s handler ", exception_name(sig, buf, O_BUFLEN));
4891 tty->print("expected:%s", get_signal_handler_name(jvmHandler, buf, O_BUFLEN));
4892 tty->print_cr(" found:%s", get_signal_handler_name(thisHandler, buf, O_BUFLEN));
4896 tty->print("Warning: %s handler flags ", exception_name(sig, buf, O_BUFLEN));
4905 print_signal_handlers(tty, buf, O_BUFLEN);
5000 const char* os::exception_name(int exception_code, char* buf, size_t size) {
5004 jio_snprintf(buf, size, "%s", signames[exception_code]);
5006 jio_snprintf(buf, size, "SIG%d", exception_code);
5008 return buf;
5553 typedef int (*vsnprintf_t)(char* buf, size_t count, const char* fmt, va_list argptr);
5556 int local_vsnprintf(char* buf, size_t count, const char* fmt, va_list argptr) {
5570 return (*sol_vsnprintf)(buf, count, fmt, argptr);
5584 char buf[sizeof(struct dirent) + MAX_PATH];
5585 struct dirent *dbuf = (struct dirent *) buf;
5839 struct stat buf;
5841 while (::stat(filename, &buf) == 0) {
6682 char buf[MAXPATHLEN];
6689 os::jvm_path(buf, sizeof(buf));
6692 p = strrchr(buf, '/');
6697 p = strrchr(buf, '/');
6702 strcpy(libmawtpath, buf);
6707 strcpy(libmawtpath, buf);
6714 size_t os::write(int fd, const void *buf, unsigned int nBytes) {
6715 INTERRUPTIBLE_RETURN_INT(::write(fd, buf, nBytes), os::Solaris::clear_interrupted);
6726 int os::recv(int fd, char* buf, size_t nBytes, uint flags) {
6727 INTERRUPTIBLE_RETURN_INT((int)::recv(fd, buf, nBytes, flags), os::Solaris::clear_interrupted);
6730 int os::send(int fd, char* buf, size_t nBytes, uint flags) {
6731 INTERRUPTIBLE_RETURN_INT((int)::send(fd, buf, nBytes, flags), os::Solaris::clear_interrupted);
6734 int os::raw_send(int fd, char* buf, size_t nBytes, uint flags) {
6735 RESTARTABLE_RETURN_INT((int)::send(fd, buf, nBytes, flags));
6804 int os::recvfrom(int fd, char* buf, size_t nBytes, uint flags,
6806 INTERRUPTIBLE_RETURN_INT((int)::recvfrom(fd, buf, nBytes, flags, from, fromlen),\
6810 int os::sendto(int fd, char* buf, size_t len, uint flags,
6812 INTERRUPTIBLE_RETURN_INT((int)::sendto(fd, buf, len, flags, to, tolen),\