patch-2.4.21 linux-2.4.21/drivers/telephony/ixj.c

Next file: linux-2.4.21/drivers/usb/CDCEther.c
Previous file: linux-2.4.21/drivers/sound/via82cxxx_audio.c
Back to the patch index
Back to the overall index

diff -urN linux-2.4.20/drivers/telephony/ixj.c linux-2.4.21/drivers/telephony/ixj.c
@@ -6001,12 +6001,14 @@
 		if(ixjdebug & 0x0001) {
 			printk(KERN_INFO "Could not copy cadence to kernel\n");
 		}
+		kfree(lcp);
 		return -EFAULT;
 	}
 	if (lcp->filter > 5) {
 		if(ixjdebug & 0x0001) {
 			printk(KERN_INFO "Cadence out of range\n");
 		}
+		kfree(lcp);
 		return -1;
 	}
 	j->cadence_f[lcp->filter].state = 0;

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)