module: Fix off-by-one error in findpath()
authorMatt Fleming <matt.fleming@intel.com>
Tue, 27 Nov 2012 16:25:37 +0000 (16:25 +0000)
committerMatt Fleming <matt.fleming@intel.com>
Tue, 27 Nov 2012 21:09:44 +0000 (21:09 +0000)
commit6f4575c2ad3950af53bcdfd40fe2cce6171179fe
tree4a8f49a5e93a95d5caa80a9edf3e24780de42858
parent30ebd4f6bc83fa4832b658705d4020cb82dfdaea
module: Fix off-by-one error in findpath()

We need to make sure that 'path' still has enough space to write the
trailing NUL-byte. Without this patch it's possible to write a
NUL-byte past the end of the on-stack buffer.

Signed-off-by: Matt Fleming <matt.fleming@intel.com>
com32/lib/sys/module/common.c