Re:The Resurgence of C Programming
by Sanddancer on Tuesday December 27, 2016 @04:15PM
(#13266245)
The C/C++ toolchain has been working to add guards and guides to their sharp tools. Things like the various sanitizers in the llvm toolset have already meant that a lot of bugs that would have been released are instead fixed beforehand. You also have things like OpenBSD's implementation of malloc which also helps in the software feedback loop in finding logic errors that allow for things like use after free errors. C still requires attention, but there are a lot of places where it's harder to cut yourself.
[ Parent
| on HN ]
I personally use libtalloc [0] for my allocations in C. Small footprint, excellent feature set, and it has heap checks, reference counting and all the gizmos you'd like in an allocation library. It's actually awesome, I highly recommend it.
For C 'gotcha' cleanups, you can use cppcheck of course (highly recommended) but there's also 'scan-build' the static analyzed from clang.
Re:The Resurgence of C Programming
by RustyRussell on Tuesday December 27, 2016 @05:31PM
(#13266784)
Love talloc: just taking the opportunity to plug ccan/tal which I wrote after hacking on talloc for a bit: