Skip to content

random: Initialize the mode field when seeding in php_random_default_status() #13608

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 6, 2024

Conversation

TimWolla
Copy link
Member

@TimWolla TimWolla commented Mar 6, 2024

This is a follow-up fix for GH-13579. The issue was detected in the nightly MSAN build.

…lt_status()`

This is a follow-up fix for phpGH-13579. The issue was detected in the nightly
MSAN build.
@TimWolla
Copy link
Member Author

TimWolla commented Mar 6, 2024

Failures are unrelated, merging.

@TimWolla TimWolla merged commit bf0abd1 into php:master Mar 6, 2024
@TimWolla TimWolla deleted the random-uninitialized-value branch March 6, 2024 17:57
TimWolla added a commit to TimWolla/php-src that referenced this pull request Mar 12, 2024
…lt_status()` (php#13608)

This is not just an issue due to missing initialization since moving the state
struct directly into the module globals. In earlier versions changing the mode
to `MT_RAND_PHP` within a single request would also affect the mode for
subsequent requests.

Original commit message follows:

This is a follow-up fix for phpGH-13579. The issue was detected in the nightly
MSAN build.

(cherry picked from commit bf0abd1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant