diff options
| author | Even Rouault <even.rouault@mines-paris.org> | 2018-09-22 22:59:36 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-09-22 22:59:36 +0200 |
| commit | 5d94bcd89c6e281614955c56cbfebb11b866a9dd (patch) | |
| tree | 465169f7c392ec333598dde552fa6f738311cde2 /src/lib | |
| parent | b54c06fb350d318c8e74755710b3480eae3b9911 (diff) | |
| parent | 0fa7ebe2540990f590c2247b3505ac1dc84b6eec (diff) | |
Merge pull request #1136 from reverson/master
Cast on uint ceildiv
Diffstat (limited to 'src/lib')
| -rw-r--r-- | src/lib/openjp2/opj_intmath.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/openjp2/opj_intmath.h b/src/lib/openjp2/opj_intmath.h index ad135976..754b5512 100644 --- a/src/lib/openjp2/opj_intmath.h +++ b/src/lib/openjp2/opj_intmath.h @@ -170,7 +170,7 @@ Divide an integer and round upwards static INLINE OPJ_UINT32 opj_uint_ceildiv(OPJ_UINT32 a, OPJ_UINT32 b) { assert(b); - return (a + b - 1) / b; + return (OPJ_UINT32)(((OPJ_UINT64)a + b - 1) / b); } /** |
