-
Bug
-
Resolution: Won't Fix
-
Minor
-
None
Hi,
I have a boolean function which uses 'withCoverityEnv'. Inside that code block I have an if statement and when it returns false it does not exit the function, it only exits the withCoverityEnv block
Example
boolean myFunFunction() { withCoverityEnv(coverityToolName: 'default', connectInstance: 'foo-bar') { if (someBadCondition) { echo " bad " return false } SomeMoreCode that is skipped } someMoreCodeThatGetsExecuted! return true }
so even when 'someBadCondition' happens
my code ends up returning true
since that return false only exits the 'withCoverityEnv' block