tx-only RC devices do not have a receive buffer. Signed-off-by: Sean Young <sean@xxxxxxxx> --- drivers/media/rc/lirc_dev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/rc/lirc_dev.c b/drivers/media/rc/lirc_dev.c index 7f5d109..18b4dae 100644 --- a/drivers/media/rc/lirc_dev.c +++ b/drivers/media/rc/lirc_dev.c @@ -472,7 +472,7 @@ int lirc_dev_fop_open(struct inode *inode, struct file *file) if (retval) { module_put(cdev->owner); ir->open--; - } else { + } else if (ir->buf) { lirc_buffer_clear(ir->buf); } if (ir->task) -- 2.9.3 -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html