szaszm commented on a change in pull request #1036:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1036#discussion_r603284155



##########
File path: extensions/jni/jvm/JniReferenceObjects.h
##########
@@ -137,12 +137,12 @@ class JniByteInputStream : public 
minifi::InputStreamCallback {
     }
 
     // seek to offset
-    int remaining = size;
+    gsl_Expects(size >= 0);

Review comment:
       I would prefer preconditions to be at the start of the function whenever 
possible.




-- 
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.

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


Reply via email to