V4L/DVB (6104): dvb_ca_en50221: decrement module use count on error
authorMarco Schluessler <marco@lordzodiac.de>
Sat, 25 Aug 2007 14:46:07 +0000 (11:46 -0300)
committerMauro Carvalho Chehab <mchehab@infradead.org>
Wed, 10 Oct 2007 01:06:58 +0000 (22:06 -0300)
decrement module use count on error

Signed-off-by: Marco Schluessler <marco@lordzodiac.de>
Signed-off-by: Oliver Endriss <o.endriss@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
drivers/media/dvb/dvb-core/dvb_ca_en50221.c

index 3f7479557919aea2ada0a761fa8fee882be2d64f..5c7bcb8393d20d6dd618549cb2fc400930ea32e9 100644 (file)
@@ -1535,8 +1535,10 @@ static int dvb_ca_en50221_io_open(struct inode *inode, struct file *file)
                return -EIO;
 
        err = dvb_generic_open(inode, file);
-       if (err < 0)
+       if (err < 0) {
+               module_put(ca->pub->owner);
                return err;
+       }
 
        for (i = 0; i < ca->slot_count; i++) {