Comment by flohofwoe

Comment by flohofwoe 17 hours ago

1 reply

I wouldn't depend on that too much either though, or at least not depend on padding bytes being zeroed. The compiler is free to replace the memset call with code that only zeroes the struct members, but leaves junk in the padding bytes (and the same is true when copying/assigning a struct).

Gibbon1 2 hours ago

Standard should be changed to require all uninitialized memory be set to zero.

Which includes padding bytes.