[Lldb-commits] [lldb] [lldb] Check Android API for existence of getgrgid_r() introduced in 24 (PR #124182)
via lldb-commits
lldb-commits at lists.llvm.org
Thu Jan 23 12:21:49 PST 2025
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-lldb
Author: Brad Smith (brad0)
<details>
<summary>Changes</summary>
---
Full diff: https://github.com/llvm/llvm-project/pull/124182.diff
1 Files Affected:
- (modified) lldb/source/Host/posix/HostInfoPosix.cpp (+1-1)
``````````diff
diff --git a/lldb/source/Host/posix/HostInfoPosix.cpp b/lldb/source/Host/posix/HostInfoPosix.cpp
index 23ba3177de317a..879dccfd353be5 100644
--- a/lldb/source/Host/posix/HostInfoPosix.cpp
+++ b/lldb/source/Host/posix/HostInfoPosix.cpp
@@ -119,7 +119,7 @@ std::optional<std::string> PosixUserIDResolver::DoGetUserName(id_t uid) {
}
std::optional<std::string> PosixUserIDResolver::DoGetGroupName(id_t gid) {
-#ifndef __ANDROID__
+#if !defined(__ANDROID__) || __ANDROID_API__ >= 24
char group_buffer[PATH_MAX];
size_t group_buffer_size = sizeof(group_buffer);
struct group group_info;
``````````
</details>
https://github.com/llvm/llvm-project/pull/124182
More information about the lldb-commits
mailing list