Skip to content

Commit 87bc711

Browse files
committed
Revert superfluous change
1 parent 9ad3b72 commit 87bc711

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

Zend/zend_fibers.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -260,8 +260,6 @@ static ZEND_NORETURN void zend_fiber_trampoline(void)
260260
static ZEND_NORETURN void zend_fiber_trampoline(boost_context_data data)
261261
#endif
262262
{
263-
zend_fiber_context *context = EG(current_fiber_context);
264-
265263
/* Initialize transfer struct with a copy of passed data. */
266264
#ifdef ZEND_FIBER_UCONTEXT
267265
zend_fiber_transfer transfer = *transfer_data;
@@ -271,20 +269,22 @@ static ZEND_NORETURN void zend_fiber_trampoline(boost_context_data data)
271269

272270
zend_fiber_context *from = transfer.context;
273271

272+
#ifdef __SANITIZE_ADDRESS__
273+
__sanitizer_finish_switch_fiber(NULL, &from->stack->asan_pointer, &from->stack->asan_size);
274+
#endif
275+
274276
#ifndef ZEND_FIBER_UCONTEXT
275277
/* Get the context that resumed us and update its handle to allow for symmetric coroutines. */
276278
from->handle = data.handle;
277279
#endif
278280

279-
#ifdef __SANITIZE_ADDRESS__
280-
__sanitizer_finish_switch_fiber(NULL, &from->stack->asan_pointer, &from->stack->asan_size);
281-
#endif
282-
283281
/* Ensure that previous fiber will be cleaned up (needed by symmetric coroutines). */
284282
if (from->status == ZEND_FIBER_STATUS_DEAD) {
285283
zend_fiber_destroy_context(from);
286284
}
287285

286+
zend_fiber_context *context = EG(current_fiber_context);
287+
288288
context->function(&transfer);
289289
context->status = ZEND_FIBER_STATUS_DEAD;
290290

0 commit comments

Comments
 (0)