lib: Fix potential out of bounds access in ring stop code
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Wed, 16 Apr 2014 14:05:43 +0000 (17:05 +0300)
committerVille Syrjälä <ville.syrjala@linux.intel.com>
Wed, 16 Apr 2014 16:21:17 +0000 (19:21 +0300)
commit78e4c2b449c6d0a18e2bfaea29f3a0eadb42c5f3
tree27a4d8ffcfeb5c913e0997c0329919fef614cf3a
parent4aa2c102b933d11cc85e0dc6fe607924e248b652
lib: Fix potential out of bounds access in ring stop code

The subsequet code expects the read() to not have filled the entire
buffer, and yet we allow it to do so. Reduce the size passed to read()
by 1 to make the code sane.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
lib/igt_debugfs.c