summaryrefslogtreecommitdiffstats
path: root/cpukit/libcsupport/src/link.c
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2000-08-11 20:04:27 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2000-08-11 20:04:27 +0000
commitdd19c0bb061af5595a970ed3c4f4af3824b65593 (patch)
treef946b796fc8e82900702a771e6f6c6b39cbe2297 /cpukit/libcsupport/src/link.c
parent2000-08-11 Charles-Antoine Gauthier <charles.gauthier@nrc.ca> (diff)
downloadrtems-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/libcsupport/src/link.c')
-rw-r--r--cpukit/libcsupport/src/link.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/cpukit/libcsupport/src/link.c b/cpukit/libcsupport/src/link.c
index 5bf8f90353..03bdaee343 100644
--- a/cpukit/libcsupport/src/link.c
+++ b/cpukit/libcsupport/src/link.c
@@ -41,8 +41,16 @@ int link(
*/
rtems_filesystem_get_start_loc( new, &i, &parent_loc );
+
+ if ( !parent_loc.ops->evalformake ) {
+ rtems_filesystem_freenode( &existing_loc );
+ rtems_filesystem_freenode( &parent_loc );
+ set_errno_and_return_minus_one( ENOTSUP );
+ }
+
result = (*parent_loc.ops->evalformake)( &new[i], &parent_loc, &name_start );
if ( result != 0 ) {
+ rtems_filesystem_freenode( &existing_loc );
rtems_filesystem_freenode( &parent_loc );
set_errno_and_return_minus_one( result );
}