twitter / vireo

Vireo is a lightweight and versatile video processing library written in C++11
MIT License
932 stars 111 forks source link

fix: an overflow bug for div2_round #7

Closed cutezerocat closed 6 years ago

cutezerocat commented 6 years ago

There is a potential overflow bug for div2_round function.

When parameter a of function div2_round (in vireo/imagecore/utils/mathutils.h) has the maximum value, the result is 0 which is incorrect.

CLAassistant commented 6 years ago

CLA assistant check
All committers have signed the CLA.

canbal commented 6 years ago

@lukealonso this looks correct to me but please chime in as the primary owner for this piece of code.

cutezerocat commented 6 years ago

@canbal @lukealonso done.