diff options
author | Roland McGrath <roland@gnu.org> | 2001-04-01 01:39:47 +0000 |
---|---|---|
committer | Roland McGrath <roland@gnu.org> | 2001-04-01 01:39:47 +0000 |
commit | 970c84822bf6483a7d7112005708295d5e67461f (patch) | |
tree | 6d9bb941ef96433c36ed3188cfb5a34ecbcbbef7 /libdiskfs/peropen-make.c | |
parent | f56be46e466ec63a987b1576700ad48388606a49 (diff) |
2001-03-28 Neal H Walfield <neal@cs.uml.edu>
* dir-chg.c (diskfs_S_dir_notice_changes): Check what malloc
returns.
* peropen-make.c (diskfs_make_peropen): Likewise.
Diffstat (limited to 'libdiskfs/peropen-make.c')
-rw-r--r-- | libdiskfs/peropen-make.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/libdiskfs/peropen-make.c b/libdiskfs/peropen-make.c index 887658c7..a49feaf9 100644 --- a/libdiskfs/peropen-make.c +++ b/libdiskfs/peropen-make.c @@ -1,5 +1,5 @@ /* - Copyright (C) 1994, 1997, 1999 Free Software Foundation + Copyright (C) 1994, 1997, 1999, 2001 Free Software Foundation This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as @@ -25,6 +25,9 @@ diskfs_make_peropen (struct node *np, int flags, struct peropen *context) { struct peropen *po = malloc (sizeof (struct peropen)); + if (! po) + return NULL; + po->filepointer = 0; po->lock_status = LOCK_UN; po->refcnt = 0; |