Menu

#23 Discourage assert()

v3.1.3
open
nobody
None
5
2019-01-11
2019-01-11
mcandre
No

Modern C/C++ programming prefers perror() or returning error values, to using assert(). I understand this is because assert() often becomes a NOP in release binaries, and assert() can occasionally leak sensitive information.

Given that assert() is now frowned upon, could splint update its rule checks to recommend suitable replacements in our source code files?

Discussion


Log in to post a comment.

MongoDB Logo MongoDB