Skip to content

Backport fixes to use of mem::uninitialized to older versions? #2914

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

Open
5225225 opened this issue Jul 11, 2022 · 0 comments
Open

Backport fixes to use of mem::uninitialized to older versions? #2914

5225225 opened this issue Jul 11, 2022 · 0 comments

Comments

@5225225
Copy link

5225225 commented Jul 11, 2022

Background: In rust-lang/rust#66151 we're adding more strict checks in order to detect invalid use of mem::uninitialized/mem::zeroed, and older versions of hyper run into this check, so it would be good to have semver compatible versions that people can cargo update -p hyper to in order to get their code working again.

0.11 is the oldest version that anyone ran into the issue on, and out of 136 regressions, there were only 4. So just publishing a fix to 0.12 (25 regressions) and 0.13 (52 regressions) would fix most of the issues. The rest of the regressions are on 0.14, but that's got a fixed version published on it, so there's nothing more to do there. (Granted, these numbers might be somewhat off because it's an old crater run, but from checking a few of them at random, there's not many that published an update since).

I'm up for doing the work needed here, I assume I'd just make a pull request to the 0.13.x / 0.12.x branch? It would lead to a perf regression to do the simplest thing of just using mem::zeroed / httparse::EMPTY_HEADER, but that seems acceptable since the crate would still at least work and not panic. Also, 0.12.x might need a bytes bump to not run into use of uninit bytes from there, which might be a MSRV bump, but again, I feel that's better than it not working.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant