This page is a permanent link to the reply below and its nested replies. See all post replies »
ElwoodBlues · M
it's just a skill issue if 6,855 flights all over the world get canceled because someone dereferenced the wrong pointer
My understanding is that the null pointer that was dereferenced by the crowdstrike kernel mode driver was in a file of updated code interpreted by the driver to recognize malware. Only the whole file was zeros!
They didn't do any sanity checks on the file before loading it into the kernel and executing!!
Anyway, back to C++. Somewhere at the back of some bookshelf I have a book called "Effective C++." It's got 55 examples of how the naive way of writing this or that code snippet doesn't do what you intend, plus the right way to write the snippet. There's also at least 1 sequel with many more such items.
After a while, I realized that the whole book is a list of bugs and workarounds!! C++ is full of garden paths or slippery slopes or whatever you want to call them, where the apparently sensible way to write the code is also the WRONG way to write the code!! There's gotta be a better way!!





