szaszm commented on code in PR #1348:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1348#discussion_r895617857


##########
libminifi/test/unit/EnvironmentUtilsTests.cpp:
##########
@@ -117,6 +117,9 @@ TEST_CASE("multithreaded environment manipulation", 
"[getenv][setenv][unsetenv]"
               utils::Environment::unsetEnvironmentVariable(env_name.c_str());
               break;
             }
+          default: {
+            throw std::runtime_error("Operation value must be modulo 3");

Review Comment:
   If it terminates, then it's impossible to accidentally catch, log and 
proceed on a programming error. It would be best if it prevented compilation, 
but since this is a runtime condition, we can only detect the condition at 
runtime. Crashing the program can not be ignored, which should prevent 
releasing with a programming error.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to