Originally Posted by
MK27
That's only true WRT "any kind of bug" -- no amount of testing can demonstrate there are no possible bugs of any sort. However, testing can demonstrate that no bug of a particular sort exists, such as a memory leak. At exit, valgrind will give you an allocated/free summary and say "All heap blocks were freed -- no leaks are possible", by which I do not think they mean "nothing is true, everything is permitted", or "there may be leaks, just we did not find any involving your computer's memory", etc.
There may be plenty of cases where that method won't work, and I've never used it myself, but I think there are plenty of cases where, logically, it will work perfectly.