HTHou opened a new pull request, #475: URL: https://github.com/apache/tsfile/pull/475
Potential fix for [https://github.com/apache/tsfile/security/code-scanning/17](https://github.com/apache/tsfile/security/code-scanning/17) To fix the issue, we need to ensure that the multiplication is performed using a larger integer type (e.g., `int64_t`) to prevent overflow. This can be achieved by explicitly casting one of the operands to `int64_t` before the multiplication. This ensures that the multiplication is performed in 64-bit arithmetic, avoiding overflow. The specific change will be made on line 191, where the multiplication `points_per_device * device_num` occurs. We will cast `points_per_device` to `int64_t` before the multiplication. This change does not alter the logic or functionality of the code but ensures that the multiplication is safe. --- _Suggested fixes powered by Copilot Autofix. Review carefully before merging._ -- 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: notifications-unsubscr...@tsfile.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org