aboutsummaryrefslogtreecommitdiff
path: root/net/unix/af_unix.c
diff options
context:
space:
mode:
authorLars-Peter Clausen <[email protected]>2012-09-12 12:06:00 +0100
committerJonathan Cameron <[email protected]>2012-09-22 10:55:08 +0100
commit3fff22743640637c2b61473d3cc8d7dc2215984f (patch)
tree2e7d8751b60e245e18a8f14282aebf0e03c53360 /net/unix/af_unix.c
parente60fea794e6ecb9ea4df2623c9498412afe31d4d (diff)
staging:iio:dummy: Fix potential NULL pointer dereference
If the config contains CONFIG_IIO_BUFFER=y and CONFIG_IIO_SIMPLE_DUMMY_BUFFER=n iio_simple_dummy_configure_buffer() is stubbed out and iio_buffer_register() is not. As a result we try to register a buffer which has not been configured. This will causes a NULL pointer deref in iio_buffer_register. To solve this issue move the iio_buffer_register() call to iio_simple_dummy_configure_buffer(), so it will only be called if iio_simple_dummy_configure_buffer() has been called. Reported-by: Fengguang Wu <[email protected]> Signed-off-by: Lars-Peter Clausen <[email protected]> Signed-off-by: Jonathan Cameron <[email protected]>
Diffstat (limited to 'net/unix/af_unix.c')
0 files changed, 0 insertions, 0 deletions