test: fix volatile for CauseSegfault with clang
PR-URL: https://github.com/nodejs/node/pull/54325 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: James M Snell <jasnell@gmail.com>
This commit is contained in:
parent
8882a21b04
commit
38974a2eb3
@ -73,7 +73,7 @@ static void Abort(const FunctionCallbackInfo<Value>& args) {
|
||||
// For internal testing only, not exposed to userland.
|
||||
static void CauseSegfault(const FunctionCallbackInfo<Value>& args) {
|
||||
// This should crash hard all platforms.
|
||||
volatile void** d = static_cast<volatile void**>(nullptr);
|
||||
void* volatile* d = static_cast<void* volatile*>(nullptr);
|
||||
*d = nullptr;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user