Commit Graph

9 Commits

Author SHA1 Message Date
Edward Thomson
f1453c59b2 Make our overflow check look more like gcc/clang's
Make our overflow checking look more like gcc and clang's, so that
we can substitute it out with the compiler instrinsics on platforms
that support it.  This means dropping the ability to pass `NULL` as
an out parameter.

As a result, the macros also get updated to reflect this as well.
2015-02-13 09:27:33 -05:00
Edward Thomson
2884cc42de overflow checking: don't make callers set oom
Have the ALLOC_OVERFLOW testing macros also simply set_oom in the
case where a computation would overflow, so that callers don't
need to.
2015-02-12 22:54:47 -05:00
Edward Thomson
392702ee2c allocations: test for overflow of requested size
Introduce some helper macros to test integer overflow from arithmetic
and set error message appropriately.
2015-02-12 22:54:46 -05:00
Jared Wong
307a3d6762 Fixed left shift size of int.
Simply switched the ordering of the checks in the for loop where this left
shift was being made.
2013-12-08 01:50:10 -08:00
Russell Belfer
9007c53fae Fixing unwrapped calloc 2013-05-27 16:45:22 -07:00
Edward Thomson
359fc2d241 update copyrights 2013-01-08 17:31:27 -06:00
Philip Kelley
f6ed5e2d05 Revert changes from git/git diff-delta.c by dak@gnu.org, proski@gnu.org 2013-01-07 09:53:43 -05:00
Russell Belfer
a8122b5d4a Fix warnings on Win64 build 2012-11-27 13:18:29 -08:00
Michael Schubert
ec1d42b7d5 Add diff-delta code from git.git 2012-10-09 21:28:31 +02:00