A longstanding GnuTLS certificate validation botch
A longstanding GnuTLS certificate validation botch
Posted Mar 6, 2014 12:28 UTC (Thu) by dgm (subscriber, #49227)In reply to: A longstanding GnuTLS certificate validation botch by Karellen
Parent article: A longstanding GnuTLS certificate validation botch
I see where are you coming from, but I cannot agree. strcmp() is not for checking equality, even if you can use it for that. It's an order operator, because the sign of the return value matters, so the return value cannot be a boolean.
In any case the _only_ way to remove error paths -either implicit or explicit- from your code is to create complete functions (http://en.wikipedia.org/wiki/Functional_completeness) whenever possible.