* libfs/src/imfs/imfs_creat.c: Reject creation of FIFOs if support is
	disabled.
This commit is contained in:
Sebastian Huber
2010-06-08 15:15:31 +00:00
parent 13dc9c6ae7
commit 68cd765a22
2 changed files with 15 additions and 2 deletions
+5
View File
@@ -1,3 +1,8 @@
2010-06-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
* libfs/src/imfs/imfs_creat.c: Reject creation of FIFOs if support is
disabled.
2010-06-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
PR 1524/filesystem
+10 -2
View File
@@ -45,6 +45,16 @@ IMFS_jnode_t *IMFS_create_node(
if ( parent_loc == NULL )
return NULL;
parent = parent_loc->node_access;
fs_info = parent_loc->mt_entry->fs_info;
/*
* Reject creation of FIFOs if support is disabled.
*/
if ( type == IMFS_FIFO &&
fs_info->fifo_handlers == &rtems_filesystem_null_handlers )
return NULL;
/*
* Allocate filesystem node and fill in basic information
*/
@@ -96,8 +106,6 @@ IMFS_jnode_t *IMFS_create_node(
/*
* This node MUST have a parent, so put it in that directory list.
*/
parent = parent_loc->node_access;
fs_info = parent_loc->mt_entry->fs_info;
node->Parent = parent;
node->st_ino = ++fs_info->ino_count;