Skip to content

Commit

Permalink
Fix a compilation failure in AIX
Browse files Browse the repository at this point in the history
AIX (at least for 7.1)  defines some macros for "events" and "revents" which
interferes with our own use of these names.

Fixes #24236

Reviewed-by: Neil Horman <[email protected]>
Reviewed-by: Tomas Mraz <[email protected]>
(Merged from openssl/openssl#26933)
  • Loading branch information
mattcaswell authored and nhorman committed Mar 4, 2025
1 parent ac80e1e commit 5eb55ad
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions ssl/rio/poll_immediate.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,16 @@
#include "../ssl_local.h"
#include "poll_builder.h"

#if defined(_AIX)
/*
* Some versions of AIX define macros for events and revents for use when
* accessing pollfd structures (see Github issue #24236). That interferes
* with our use of these names here. We simply undef them.
*/
# undef revents
# undef events
#endif

#define ITEM_N(items, stride, n) \
(*(SSL_POLL_ITEM *)((char *)(items) + (n)*(stride)))

Expand Down

0 comments on commit 5eb55ad

Please sign in to comment.