From adcf3f2a55cfcce391e5205fdc6ca986ca7f9f26 Mon Sep 17 00:00:00 2001 From: Thomas Bushnell Date: Wed, 20 Aug 1997 19:04:49 +0000 Subject: Wed Aug 20 14:29:11 1997 Thomas Bushnell, n/BSG * pager.c (diskfs_get_filemap): If pager_create fails, return error to caller. --- isofs/ChangeLog | 5 +++++ isofs/pager.c | 7 +++++++ 2 files changed, 12 insertions(+) (limited to 'isofs') diff --git a/isofs/ChangeLog b/isofs/ChangeLog index b4235a2d..ee961d51 100644 --- a/isofs/ChangeLog +++ b/isofs/ChangeLog @@ -1,3 +1,8 @@ +Wed Aug 20 14:29:11 1997 Thomas Bushnell, n/BSG + + * pager.c (diskfs_get_filemap): If pager_create fails, return + error to caller. + Tue Aug 19 14:20:09 1997 Thomas Bushnell, n/BSG * rr.c (rrip_work) [SL]: Component length field does not include diff --git a/isofs/pager.c b/isofs/pager.c index f02d2f35..3ebcc7e8 100644 --- a/isofs/pager.c +++ b/isofs/pager.c @@ -165,6 +165,13 @@ diskfs_get_filemap (struct node *np, vm_prot_t prot) upi->np = np; diskfs_nref_light (np); upi->p = pager_create (upi, pager_bucket, 1, MEMORY_OBJECT_COPY_DELAY); + if (upi->p == 0) + { + diskfs_nrele_light (np); + free (upi); + spin_unlock (&node2pagelock); + return MACH_PORT_NULL; + } np->dn->fileinfo = upi; right = pager_get_port (np->dn->fileinfo->p); ports_port_deref (np->dn->fileinfo->p); -- cgit v1.2.3