vibhatha commented on code in PR #39529:
URL: https://github.com/apache/arrow/pull/39529#discussion_r1457087148


##########
java/vector/src/main/java/org/apache/arrow/vector/util/Text.java:
##########
@@ -202,15 +202,17 @@ public int find(String what, int start) {
   public void set(String string) {
     try {
       ByteBuffer bb = encode(string, true);
-      bytes = bb.array();
+      bytes = new byte[bb.remaining()];
+      bb.get(bytes);
+      bb.position(bb.position() - bytes.length); // move it back so we can 
decode it

Review Comment:
   I reversed the change to check the original warning message, it doesn't show 
up anymore. 
   This could be because of https://github.com/apache/arrow/pull/39452 and me 
not rebasing at the time :thinking: 



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