Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
dullcrisp
on Oct 18, 2024
|
parent
|
context
|
favorite
| on:
C++ proposal: There are exactly 8 bits in a byte
You think no one checks if their arithmetic overflows?
Spivak
on Oct 18, 2024
[–]
I'm sure it's not literally no one but I bet the percent of additions that have explicit checks for overflow is for all practical purposes indistinguishable from 0.
nox101
on Oct 18, 2024
|
parent
[–]
Lots of secure code checks for overflow
fillBufferWithData(buffer, data, offset, size)
You want to know that offset + size don't wrap past 32bits (or 64) and end up with nonsense and a security vulnerability.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: