summaryrefslogtreecommitdiffstats
path: root/cpukit
diff options
context:
space:
mode:
authorJennifer Averett <Jennifer.Averett@OARcorp.com>2000-11-17 18:46:03 +0000
committerJennifer Averett <Jennifer.Averett@OARcorp.com>2000-11-17 18:46:03 +0000
commit13e47e2e6bb80d87ccad7be9c26a04968b7a44ca (patch)
treeeda7f9412dc7589b9333b4b04cef514146ae78dd /cpukit
parent2000-11-17 Jennifer Averret <jennifer@OARcorp.com> (diff)
downloadrtems-13e47e2e6bb80d87ccad7be9c26a04968b7a44ca.tar.bz2
2000-11-17 Jennifer Averret <jennifer@OARcorp.com>
* src/imfs/imfs_eval.c: Always return imaginary node at mount points.
Diffstat (limited to 'cpukit')
-rw-r--r--cpukit/libfs/ChangeLog4
-rw-r--r--cpukit/libfs/src/imfs/imfs_eval.c32
2 files changed, 20 insertions, 16 deletions
diff --git a/cpukit/libfs/ChangeLog b/cpukit/libfs/ChangeLog
index fe5c92c5ad..3f8aae5fee 100644
--- a/cpukit/libfs/ChangeLog
+++ b/cpukit/libfs/ChangeLog
@@ -1,3 +1,7 @@
+2000-11-17 Jennifer Averret <jennifer@OARcorp.com>
+
+ * src/imfs/imfs_eval.c: Always return imaginary node at mount points.
+
2000-11-09 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
* Makefile.am: Use ... instead of RTEMS_TOPdir in ACLOCAL_AMFLAGS.
diff --git a/cpukit/libfs/src/imfs/imfs_eval.c b/cpukit/libfs/src/imfs/imfs_eval.c
index ebfe6c0f9b..913fddeaa7 100644
--- a/cpukit/libfs/src/imfs/imfs_eval.c
+++ b/cpukit/libfs/src/imfs/imfs_eval.c
@@ -608,17 +608,26 @@ int IMFS_eval_path(
}
/*
- * Only return root node if this is the base file system.
+ * Always return the root node.
+ *
+ * If we are at a node that is a mount point. Set loc to the
+ * new fs root node and let let the mounted filesystem set the handlers.
+ *
+ * NOTE: The behavior of stat() on a mount point appears to be questionable.
*/
- if ((pathloc->node_access == pathloc->mt_entry->mt_fs_root.node_access) &&
- (pathloc->node_access != rtems_filesystem_root.node_access) ) {
- newloc = pathloc->mt_entry->mt_point_node;
- *pathloc = newloc;
+ if ( node->type == IMFS_DIRECTORY ) {
+ if ( node->info.directory.mt_fs != NULL ) {
+ newloc = node->info.directory.mt_fs->mt_fs_root;
+ *pathloc = newloc;
+ return (*pathloc->ops->evalpath_h)( &pathname[i-len], flags, pathloc );
+ } else {
+ result = IMFS_Set_handlers( pathloc );
+ }
+ } else {
+ result = IMFS_Set_handlers( pathloc );
}
- result = IMFS_Set_handlers( pathloc );
-
/*
* Verify we have the correct permissions for this node.
*/
@@ -628,12 +637,3 @@ int IMFS_eval_path(
return result;
}
-
-
-
-
-
-
-
-
-