guan404ming opened a new pull request, #375:
URL: https://github.com/apache/tvm-ffi/pull/375

   ## Why
   
   Integer overflow in `GetDataSize` function causes incorrect buffer size 
calculation when computing data size for tensors with large element counts, 
leading to buffer underallocation and potential heap overflow.
   
   ## How
   
   - Add overflow check before multiplication
   - Handle edge case where numel is zero to avoid division by zero
   - Add tests for overflow detection


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