linux-audit / audit-userspace

Linux audit userspace repository
GNU General Public License v2.0
567 stars 201 forks source link

lib: avoid UB on sequence wrap-around #347

Closed cgzones closed 5 months ago

cgzones commented 5 months ago

Signed integer overflow is undefined, allowing compilers to optimize the condition ++sequence < 0 away.

stevegrubb commented 5 months ago

Thanks for the patch