patch-2.4.6 linux/net/atm/mpc.c

Next file: linux/net/atm/signaling.c
Previous file: linux/net/atm/lec.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.5/linux/net/atm/mpc.c linux/net/atm/mpc.c
@@ -772,6 +772,8 @@
 	if (mpc == NULL) {
 		dprintk("mpoa: mpoad_attach: allocating new mpc for itf %d\n", arg);
 		mpc = alloc_mpc();
+		if (mpc == NULL)
+			return -ENOMEM;
 		mpc->dev_num = arg;
 		mpc->dev = find_lec_by_itfnum(arg); /* NULL if there was no lec */
 	}

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