diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2000-08-11 20:04:27 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2000-08-11 20:04:27 +0000 |
commit | dd19c0bb061af5595a970ed3c4f4af3824b65593 (patch) | |
tree | f946b796fc8e82900702a771e6f6c6b39cbe2297 /cpukit/libfs | |
parent | 2000-08-11 Charles-Antoine Gauthier <charles.gauthier@nrc.ca> (diff) | |
download | rtems-dd19c0bb061af5595a970ed3c4f4af3824b65593.tar.bz2 |
2000-08-11 Chris Johns <ccj@acm.org>
* libc/chmod.c: Return ENOTSUP if filesystem does not have handler.
* libc/eval.c: Ditto.
* libc/fcntl.c: Ditto.
* libc/fsync.c: Ditto.
* libc/ioctl.c: Ditto.
* libc/ioman.c: Ditto.
* libc/link.c: Ditto.
* libc/memfile.c: Ditto.
* libc/mknod.c: Ditto.
* libc/symlink.c: Ditto.
* libc/libio.h(rtems_filesystem_dev_major_t): New macro.
* libc/libio.h(rtems_filesystem_dev_minor_t): New macro.
Diffstat (limited to 'cpukit/libfs')
-rw-r--r-- | cpukit/libfs/src/imfs/ioman.c | 5 | ||||
-rw-r--r-- | cpukit/libfs/src/imfs/memfile.c | 4 |
2 files changed, 8 insertions, 1 deletions
diff --git a/cpukit/libfs/src/imfs/ioman.c b/cpukit/libfs/src/imfs/ioman.c index ee22791657..4f592a6094 100644 --- a/cpukit/libfs/src/imfs/ioman.c +++ b/cpukit/libfs/src/imfs/ioman.c @@ -80,6 +80,11 @@ rtems_status_code rtems_io_lookup_name( result = rtems_filesystem_evaluate_path( name, 0x00, &loc, TRUE ); the_jnode = loc.node_access; + if ( !loc.ops->node_type ) { + rtems_filesystem_freenode( &loc ); + set_errno_and_return_minus_one( ENOTSUP ); + } + node_type = (*loc.ops->node_type)( &loc ); if ( (result != 0) || node_type != RTEMS_FILESYSTEM_DEVICE ) { diff --git a/cpukit/libfs/src/imfs/memfile.c b/cpukit/libfs/src/imfs/memfile.c index a2dc695044..9974a3d2d5 100644 --- a/cpukit/libfs/src/imfs/memfile.c +++ b/cpukit/libfs/src/imfs/memfile.c @@ -112,6 +112,9 @@ int memfile_close( the_jnode = iop->file_info; + if (iop->flags & LIBIO_FLAGS_APPEND) + iop->offset = the_jnode->info.file.size; + return 0; } @@ -340,7 +343,6 @@ MEMFILE_STATIC int IMFS_memfile_addblock( #endif memory = memfile_alloc_block(); - assert( memory ); if ( !memory ) return 1; *block_entry_ptr = memory; |