Lines Matching refs:buf
780 char buf[257]; /* recommended buffer size from sysinfo man
785 length = sysinfo(SI_ISALIST, buf, 257);
787 location = strstr(buf, "sparcv8plus ");
821 * "/foo" into buf.
824 GetApplicationHome(char *buf, jint bufsize)
829 strncpy(buf, execname, bufsize-1);
830 buf[bufsize-1] = '\0';
838 if (realpath(dlinfo.dli_fname, buf) == NULL) {
852 snprintf(buf, bufsize, "%s", java_home_var);
855 if (strrchr(buf, '/') == 0) {
856 buf[0] = '\0';
859 *(strrchr(buf, '/')) = '\0'; /* executable file */
860 if (strlen(buf) < 4 || strrchr(buf, '/') == 0) {
861 buf[0] = '\0';
864 if (strcmp("/bin", buf + strlen(buf) - 4) != 0)
865 *(strrchr(buf, '/')) = '\0'; /* sparcv9 or amd64 */
866 if (strlen(buf) < 4 || strcmp("/bin", buf + strlen(buf) - 4) != 0) {
867 buf[0] = '\0';
870 *(strrchr(buf, '/')) = '\0'; /* bin */
927 char buf[PATH_MAX+2];
998 char buf[PATH_MAX+1];
999 int len = readlink(self, buf, PATH_MAX);
1001 buf[len] = '\0'; /* readlink doesn't nul terminate */
1002 exec_path = JLI_StringDup(buf);