patch-2.4.5 linux/drivers/ieee1394/video1394.c

Next file: linux/drivers/isdn/avmb1/avmcard.h
Previous file: linux/drivers/ide/slc90e66.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.4/linux/drivers/ieee1394/video1394.c linux/drivers/ieee1394/video1394.c
@@ -302,12 +302,12 @@
 
 	d = (struct dma_iso_ctx *)kmalloc(sizeof(struct dma_iso_ctx), 
 					  GFP_KERNEL);
-	memset(d, 0, sizeof(struct dma_iso_ctx));
-
 	if (d==NULL) {
 		PRINT(KERN_ERR, ohci->id, "failed to allocate dma_iso_ctx");
 		return NULL;
 	}
+
+	memset(d, 0, sizeof(struct dma_iso_ctx));
 
 	d->ohci = (void *)ohci;
 	d->ctx = ctx;

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