[quake3-commits] [ioquake/ioq3] b3223d: [qcommon] Use unsigned types where wrapping arithm...

Thomas Köppe tkoeppe at google.com
Mon Oct 2 20:46:39 EDT 2017

  Branch: refs/heads/master
  Home:   https://github.com/ioquake/ioq3
  Commit: b3223dcfcb83d7054eb232af3bd4ea50827558ad
  Author: Thomas Köppe <tkoeppe at google.com>
  Date:   2017-10-02 (Mon, 02 Oct 2017)

  Changed paths:
    M code/qcommon/common.c
    M code/qcommon/q_math.c

  Log Message:
  [qcommon] Use unsigned types where wrapping arithmetic is intended

The use of signed types in these expressions lead to overflow, hence undefined behaviour. The "sum" aggregator in Com_TouchMemory isn't even used (and presumbably just exists to inhibit optimizations from removing the memory access).

More information about the quake3-commits mailing list