lkml.org 
[lkml]   [2001]   [Jun]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] riocmd.c
Date
Hi,

This patch fixes an instance where a pointer is not checked after allocation.

Praveen Srinivasan

--- ../linux-fresh/./drivers/char/rio/riocmd.c Fri Feb 9 11:30:23 2001
+++ ./drivers/char/rio/riocmd.c Wed May 23 12:31:01 2001
@@ -623,6 +623,9 @@
struct CmdBlk *CmdBlkP;

CmdBlkP = (struct CmdBlk *)sysbrk(sizeof(struct CmdBlk));
+ if(CmdBlkP == NULL){
+ return NULL;
+ }
bzero(CmdBlkP, sizeof(struct CmdBlk));

return CmdBlkP;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2005-03-22 12:55    [W:0.047 / U:0.160 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site