News for hackers. Stuff that matters.

chilljinx

Re:Memory safety CVEs differ between Rust and C/C++ on Monday June 15, 2026 @01:46PM (#48544697)
Are you breaking the rules of the site?
Re:Memory safety CVEs differ between Rust and C/C++ on Monday June 15, 2026 @01:44PM (#48544673)
> no_std

Is 100% relevant.

Did you use ChatGPT to generate your comment?

Re:Memory safety CVEs differ between Rust and C/C++ on Monday June 15, 2026 @01:42PM (#48544653)
I do not believe that I agree, and I am not sure about all of your numbers.

The borrow checker does add something, but it definitely costs something as well in multiple ways, also in terms of how it is done in Rust and at a programming language design perspective.

It would be very funny if you were batting for Rust, and just having a laugh at others here.

Re:Memory safety CVEs differ between Rust and C/C++ on Monday June 15, 2026 @01:37PM (#48544571)
Which definition of UB are you using regarding that? Behavior changing based on configuration does not seem like UB, at least if none of the configurations allow for UB.
Re:Memory safety CVEs differ between Rust and C/C++ on Monday June 15, 2026 @01:19PM (#48544344)
Unsafe is not necessary to trigger UB in case no_std is used. Nor if one of the soundness holes in the Rust programming language itself is encountered. Nor if there is UB in one of the libraries used as a dependency by the library you are using. Nor if there is UB in the Rust standard library. Which has happened many times, since the Rust standard library is full of unsafe.

Rust also requires libraries to be safe regarding unsafe, no matter what kind of insane input that is given to the library and that would otherwise potentially be security issues. Which is too difficult for many library authors.

And unsafe in Rust is so difficult that many library authors throw their hands up, use Miri, and hope for the best. Even though Miri, all respect to it, has bugs, probability-based testing and other limitations and issues.

UB in both user library and standard library:

https://materialize.com/blog/rust-concurrency-bug-unbounded-...