]> git.eshelyaron.com Git - emacs.git/commit
alloc.c: ckd_add, not by-hand checks
authorPaul Eggert <eggert@cs.ucla.edu>
Sun, 14 Jul 2024 22:37:50 +0000 (23:37 +0100)
committerEshel Yaron <me@eshelyaron.com>
Wed, 17 Jul 2024 21:53:48 +0000 (23:53 +0200)
commita51474e9e5f0999dcdf7ff5d24e3cad9a6939eba
treef05adcd9ed9fce6fc15d0b1617eeaf53e165c17b
parentf96cd9a42f2ffa262a3ffd9a71bb87a9baabccec
alloc.c: ckd_add, not by-hand checks

* src/alloc.c (lmalloc, lrealloc): Prefer ckd_add to
by-hand checks for integer addition overflow.

(cherry picked from commit b77abd2bfeb13ae046b1f8c6157bd5a497665657)
src/alloc.c