]> git.michaelhowe.org Git - packages/o/openafs.git/commit
unlog: Don't overflow cells array
authorSimon Wilkinson <sxw@your-file-system.com>
Fri, 1 Mar 2013 11:31:31 +0000 (11:31 +0000)
committerDerrick Brashear <shadow@your-file-system.com>
Mon, 4 Mar 2013 03:01:52 +0000 (19:01 -0800)
commitff7fd58b49a41bf85df492b9f470004d4433800e
tree8798bd8c6b0d85435a670ba4c17792ea9f9adcb7
parent30e25c74376dd8aa24018116015e57c47c1dfaf9
unlog: Don't overflow cells array

cells has a maximum size of MAXCELLS. Doing cells[MAXCELLS] overflows
that array. Clamp our maximum number of cells at one below this to
avoid the overflow.

Caught by coverity (#98551)

Change-Id: I45fd8a55e31ad7ea86a996b593359536c7078891
Reviewed-on: http://gerrit.openafs.org/9324
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
src/log/unlog.c