Skip to content

Commit

Permalink
Fix for buffer data when created with an offset.
Browse files Browse the repository at this point in the history
Signed-off-by: Tomas Langer <tomas.langer@oracle.com>
  • Loading branch information
tomas-langer committed Jan 17, 2024
1 parent bd1c11f commit af61d6e
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2022 Oracle and/or its affiliates.
* Copyright (c) 2022, 2024 Oracle and/or its affiliates.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -43,7 +43,7 @@ class FixedBufferData implements BufferData {
FixedBufferData(byte[] bytes, int position, int length) {
this.bytes = bytes;
this.length = length;
this.writePosition = length;
this.writePosition = position + length;
this.readPosition = position;
}

Expand Down

0 comments on commit af61d6e

Please sign in to comment.