File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
libc/src/__support/OSUtil/linux Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -96,15 +96,17 @@ LIBC_INLINE void Vector::fallback_initialize_unsync() {
9696 }
9797 size_t avaiable_size = AUXV_MMAP_SIZE - sizeof (Entry);
9898
99- // Attempt 1: use PRCTL to get the auxv.
100- // We guarantee that the vector is always padded with AT_NULL entries.
99+ // Attempt 1: use PRCTL to get the auxv.
100+ // We guarantee that the vector is always padded with AT_NULL entries.
101+ #ifdef PR_GET_AUXV
101102 long prctl_ret = syscall_impl<long >(SYS_prctl, PR_GET_AUXV,
102103 reinterpret_cast <unsigned long >(vector),
103104 avaiable_size, 0 , 0 );
104105 if (prctl_ret >= 0 ) {
105106 entries = vector;
106107 return ;
107108 }
109+ #endif
108110
109111 // Attempt 2: read /proc/self/auxv.
110112#ifdef SYS_openat
You can’t perform that action at this time.
0 commit comments