nvollmar commented on code in PR #2847:
URL: https://github.com/apache/pekko/pull/2847#discussion_r3040723813


##########
actor/src/main/scala-2.13/org/apache/pekko/util/ByteIterator.scala:
##########
@@ -141,6 +141,45 @@ object ByteIterator {
       } else throw new NoSuchElementException("next on empty iterator")
     }
 
+    override def getShort(implicit byteOrder: ByteOrder): Short = {
+      if (len < 2) throw new NoSuchElementException("next on empty iterator")
+      if (byteOrder == ByteOrder.BIG_ENDIAN) {
+        val result = SWARUtil.getShort(array, from)

Review Comment:
   Might be more explicit passing `bigEndian = true` as well



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to