Lines Matching refs:buffer
97 int uv_exepath(char* buffer, size_t* size_ptr) { in uv_exepath() argument
102 if (buffer == NULL || size_ptr == NULL || *size_ptr == 0) { in uv_exepath()
127 err = uv_utf16_to_wtf8(utf16_buffer, utf16_len, &buffer, &utf8_len); in uv_exepath()
189 int uv_cwd(char* buffer, size_t* size) { in uv_cwd() argument
194 if (buffer == NULL || size == NULL) { in uv_cwd()
202 r = uv__copy_utf16_to_utf8(utf16_buffer, utf16_len, buffer, size); in uv_cwd()
390 int uv_get_process_title(char* buffer, size_t size) { in uv_get_process_title() argument
394 if (buffer == NULL || size == 0) in uv_get_process_title()
420 memcpy(buffer, process_title, len); in uv_get_process_title()
932 int uv_os_homedir(char* buffer, size_t* size) { in uv_os_homedir() argument
940 r = uv_os_getenv("USERPROFILE", buffer, size); in uv_os_homedir()
966 memcpy(buffer, pwd.homedir, len + 1); in uv_os_homedir()
974 int uv_os_tmpdir(char* buffer, size_t* size) { in uv_os_tmpdir() argument
978 if (buffer == NULL || size == NULL || *size == 0) in uv_os_tmpdir()
1013 return uv__copy_utf16_to_utf8(path, len, buffer, size); in uv_os_tmpdir()
1248 int uv_os_getenv(const char* name, char* buffer, size_t* size) { in uv_os_getenv() argument
1256 if (name == NULL || buffer == NULL || size == NULL || *size == 0) in uv_os_getenv()
1296 r = uv__copy_utf16_to_utf8(var, len, buffer, size); in uv_os_getenv()
1363 int uv_os_gethostname(char* buffer, size_t* size) { in uv_os_gethostname() argument
1366 if (buffer == NULL || size == NULL || *size == 0) in uv_os_gethostname()
1377 return uv__copy_utf16_to_utf8(buf, -1, buffer, size); in uv_os_gethostname()
1517 int uv_os_uname(uv_utsname_t* buffer) { in uv_os_uname() argument
1529 if (buffer == NULL) in uv_os_uname()
1574 version_size = sizeof(buffer->version); in uv_os_uname()
1577 buffer->version, in uv_os_uname()
1587 buffer->version[version_size++] = ' '; in uv_os_uname()
1589 version_size = sizeof(buffer->version) - version_size; in uv_os_uname()
1592 buffer->version + in uv_os_uname()
1593 sizeof(buffer->version) - version_size, in uv_os_uname()
1601 r = snprintf(buffer->sysname, in uv_os_uname()
1602 sizeof(buffer->sysname), in uv_os_uname()
1606 assert((size_t)r < sizeof(buffer->sysname)); in uv_os_uname()
1608 uv__strscpy(buffer->sysname, "Windows_NT", sizeof(buffer->sysname)); in uv_os_uname()
1612 r = snprintf(buffer->release, in uv_os_uname()
1613 sizeof(buffer->release), in uv_os_uname()
1618 assert((size_t)r < sizeof(buffer->release)); in uv_os_uname()
1625 uv__strscpy(buffer->machine, "x86_64", sizeof(buffer->machine)); in uv_os_uname()
1628 uv__strscpy(buffer->machine, "ia64", sizeof(buffer->machine)); in uv_os_uname()
1631 uv__strscpy(buffer->machine, "i386", sizeof(buffer->machine)); in uv_os_uname()
1636 buffer->machine[1] = '0' + processor_level; in uv_os_uname()
1641 uv__strscpy(buffer->machine, "i686", sizeof(buffer->machine)); in uv_os_uname()
1644 uv__strscpy(buffer->machine, "mips", sizeof(buffer->machine)); in uv_os_uname()
1648 uv__strscpy(buffer->machine, "alpha", sizeof(buffer->machine)); in uv_os_uname()
1651 uv__strscpy(buffer->machine, "powerpc", sizeof(buffer->machine)); in uv_os_uname()
1654 uv__strscpy(buffer->machine, "sh", sizeof(buffer->machine)); in uv_os_uname()
1657 uv__strscpy(buffer->machine, "arm", sizeof(buffer->machine)); in uv_os_uname()
1660 uv__strscpy(buffer->machine, "unknown", sizeof(buffer->machine)); in uv_os_uname()
1667 buffer->sysname[0] = '\0'; in uv_os_uname()
1668 buffer->release[0] = '\0'; in uv_os_uname()
1669 buffer->version[0] = '\0'; in uv_os_uname()
1670 buffer->machine[0] = '\0'; in uv_os_uname()