There was a remark from Thomas Stuefe https://github.com/openjdk/jdk24u/pull/175
Hmm, okay.
That means that when we build on an older machine, and Linux kernels change the constant in newer kernel releases, we may use the wrong number.
What I would do is this:
#define SEGV_BNDERR_value 3
#if defined(SEGV_BNDERR)
STATIC_ASSERT(SEGV_BNDERR == SEGV_BNDERR_value);
#else
#define SEGV_BNDERR SEGV_BNDERR_value
#endif
The static assert will alert us if we build on a newer Linux version and turns out we were wrong with our assumed number.
Hmm, okay.
That means that when we build on an older machine, and Linux kernels change the constant in newer kernel releases, we may use the wrong number.
What I would do is this:
#define SEGV_BNDERR_value 3
#if defined(SEGV_BNDERR)
STATIC_ASSERT(SEGV_BNDERR == SEGV_BNDERR_value);
#else
#define SEGV_BNDERR SEGV_BNDERR_value
#endif
The static assert will alert us if we build on a newer Linux version and turns out we were wrong with our assumed number.
- relates to
-
JDK-8352946 SEGV_BND signal code of SIGSEGV missing from our signal-code table
-
- Resolved
-
- links to
-
Commit(master) openjdk/jdk/6abf4e6d
-
Review(master) openjdk/jdk/24441