diff options
author | gVisor bot <gvisor-bot@google.com> | 2020-08-03 12:38:15 -0700 |
---|---|---|
committer | gVisor bot <gvisor-bot@google.com> | 2020-08-03 12:38:15 -0700 |
commit | ef11bb936b2bbb50b0ceeeb93a74b94680fff724 (patch) | |
tree | 277ab5519890f5d48b4bde4b0124730f4339dbf1 /pkg/syncevent/waiter_noasm_unsafe.go | |
parent | 1fbbc795ef8918006214032d96fa88b8a21e5e0a (diff) | |
parent | b9a49f2065732fb4ae27d24ec05e59c4ae09adb4 (diff) |
Merge pull request #3460 from zhlhahaha:1927
PiperOrigin-RevId: 324658881
Diffstat (limited to 'pkg/syncevent/waiter_noasm_unsafe.go')
-rw-r--r-- | pkg/syncevent/waiter_noasm_unsafe.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/syncevent/waiter_noasm_unsafe.go b/pkg/syncevent/waiter_noasm_unsafe.go index 1c4b0e39a..0f74a689c 100644 --- a/pkg/syncevent/waiter_noasm_unsafe.go +++ b/pkg/syncevent/waiter_noasm_unsafe.go @@ -32,8 +32,8 @@ import ( // should be aborted. // //go:nosplit -func waiterUnlock(g unsafe.Pointer, wg *unsafe.Pointer) bool { +func waiterUnlock(ptr unsafe.Pointer, wg *unsafe.Pointer) bool { // The only way this CAS can fail is if a call to Waiter.NotifyPending() // has replaced *wg with nil, in which case we should not sleep. - return atomic.CompareAndSwapPointer(wg, (unsafe.Pointer)(&preparingG), g) + return atomic.CompareAndSwapPointer(wg, (unsafe.Pointer)(&preparingG), ptr) } |