LuciferYang opened a new pull request, #1099:
URL: https://github.com/apache/arrow-java/pull/1099

   ## What's Changed
   
   Fix the precondition check in `LargeListVector.setValueCount()` where `||` 
made the condition always true (`childValueCount <= Integer.MAX_VALUE || 
childValueCount >= Integer.MIN_VALUE` is a tautology for any `long` value), 
allowing silent data corruption when `childValueCount` exceeds 
`Integer.MAX_VALUE` or is negative.
   
   Changes:
   - Replace `||` with `&&` and `Integer.MIN_VALUE` with `0` to correctly bound 
`childValueCount` to `[0, Integer.MAX_VALUE]`, consistent with 
`LargeListViewVector`
   - Add rejection tests for negative and overflow `childValueCount`
   - Add positive boundary tests for zero, valid, and `Integer.MAX_VALUE` values
   
   Closes #1098.


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