From: Erik van der Kouwe Date: Thu, 5 Aug 2010 11:37:06 +0000 (+0000) Subject: Return ENOSPC when out of inodes X-Git-Tag: v3.1.8~103 X-Git-Url: http://zhaoyanbai.com/repos/%22http:/www.isc.org/icons/doc/spin.js?a=commitdiff_plain;h=912b4e0cb76e02670f898936f09ac2f87f9146b7;p=minix.git Return ENOSPC when out of inodes --- diff --git a/servers/ext2/ialloc.c b/servers/ext2/ialloc.c index b4f491d54..e7f008dff 100644 --- a/servers/ext2/ialloc.c +++ b/servers/ext2/ialloc.c @@ -49,7 +49,7 @@ PUBLIC struct inode *alloc_inode(struct inode *parent, mode_t bits) /* Acquire an inode from the bit map. */ b = alloc_inode_bit(sp, parent, (bits & I_TYPE) == I_DIRECTORY); if (b == NO_BIT) { - err_code = ENFILE; + err_code = ENOSPC; major = (int) (sp->s_dev >> MAJOR) & BYTE; minor = (int) (sp->s_dev >> MINOR) & BYTE; ext2_debug("Out of i-nodes on device %d/%d\n", major, minor); diff --git a/servers/mfs/inode.c b/servers/mfs/inode.c index 2476231ac..31a2777cc 100644 --- a/servers/mfs/inode.c +++ b/servers/mfs/inode.c @@ -273,7 +273,7 @@ PUBLIC struct inode *alloc_inode(dev_t dev, mode_t bits) /* Acquire an inode from the bit map. */ b = alloc_bit(sp, IMAP, sp->s_isearch); if (b == NO_BIT) { - err_code = ENFILE; + err_code = ENOSPC; major = (int) (sp->s_dev >> MAJOR) & BYTE; minor = (int) (sp->s_dev >> MINOR) & BYTE; printf("Out of i-nodes on device %d/%d\n", major, minor);