Skip to content

Commit ab4f725

Browse files
committed
Use XtOffsetOf() in url_scanner_ex
Instead of a manual implementation.
1 parent fa07a9c commit ab4f725

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/standard/url_scanner_ex.re

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -656,7 +656,7 @@ static int php_url_scanner_ex_activate(int type)
656656
ctx = &BG(url_adapt_output_ex);
657657
}
658658

659-
memset(ctx, 0, ((size_t) &((url_adapt_state_ex_t *)0)->tags));
659+
memset(ctx, 0, XtOffsetOf(url_adapt_state_ex_t, tags));
660660

661661
return SUCCESS;
662662
}

0 commit comments

Comments
 (0)