News for hackers. Stuff that matters.
Re:Let’s Stop Bashing C by bluecalm on Saturday December 03, 2016 @07:54AM (#13095479)
Right. Still, in practice, if you are setting pointers to NULL after freeing them (to say "there is nothing there" if some other part of the program wants to check) you will get a crash (as the compiler won't be able to prove the pointer is NULL if setting it to NULL depends on what happens at runtime).

I agree it's not perfect solution, just something to help you catching errors in your logic (not checking for NULL when something could be NULL is a bug in program logic).

Re:Let’s Stop Bashing C by steveklabnik on Saturday December 03, 2016 @04:55PM (#13097706)
If the zero address is valid, then one aspect of "undefined behavior" is that the result is "this will actually continue to 'work' until something random goes wrong". Someone just the other day on Reddit was talking about how this is a common issue in their workplace, as they work on a system that maps valid memory to 0.