martinzink commented on code in PR #1561:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1561#discussion_r1170994644


##########
extensions/jni/jvm/JniReferenceObjects.h:
##########
@@ -128,8 +128,8 @@ class JniByteInputStream {
     return read;
   }
 
-  int64_t read(uint8_t &arr) {
-    return stream_->read(arr);
+  int64_t read(uint8_t &arr) const {

Review Comment:
   You are absolutely right, changed it in 
https://github.com/apache/nifi-minifi-cpp/pull/1561/commits/dd896082c79acc2b122a3e74ab36c527f1fee446



##########
extensions/jni/jvm/JniReferenceObjects.h:
##########
@@ -128,8 +128,8 @@ class JniByteInputStream {
     return read;
   }
 
-  int64_t read(uint8_t &arr) {
-    return stream_->read(arr);
+  int64_t read(uint8_t &arr) const {
+    return gsl::narrow<int64_t>(stream_->read(arr));

Review Comment:
   Nice catch, I've added the error check in 
https://github.com/apache/nifi-minifi-cpp/pull/1561/commits/dd896082c79acc2b122a3e74ab36c527f1fee446



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