don4get commented on code in PR #43616:
URL: https://github.com/apache/arrow/pull/43616#discussion_r1711068124


##########
go/parquet/internal/utils/bit_packing_avx2_amd64.go:
##########
@@ -45,6 +45,10 @@ func unpack32Avx2(in io.Reader, out []uint32, nbits int) int 
{
        buffer.Grow(n)
        io.CopyN(buffer, in, int64(n))
 
+       if buffer.Len() == 0 {
+               return 0
+       }

Review Comment:
   Yes you are right. I moved the condition directly on `nbits`. Since `batch` 
is already checked, it covers all cases where `n` is equal to 0. Is it OK for 
you?



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