Skip to content

Commit

Permalink
fix test for old glibc
Browse files Browse the repository at this point in the history
  • Loading branch information
devnexen committed Jul 16, 2024
1 parent 850f74f commit ca57cc2
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions compiler-rt/test/sanitizer_common/TestCases/Linux/preadv2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,14 @@
#include <sys/uio.h>
#include <unistd.h>

#if !defined(__GLIBC_PREREQ)
#define __GLIBC_PREREQ(a, b) 0
#endif

#if !__GLIBC_PREREQ(2, 26)
#define preadv2(a, b, c, d, e) preadv(a, b, c, d)
#endif

int main(void) {
int fd = open("/proc/self/stat", O_RDONLY);
char bufa[7];
Expand Down

0 comments on commit ca57cc2

Please sign in to comment.