diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 1999-10-05 16:34:20 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 1999-10-05 16:34:20 +0000 |
commit | 0139484fbdc976ffe07598d1284aad5eba3219be (patch) | |
tree | 3632f5cded6a44289b0783ad7d1fe4c617a11037 /c/src/exec/libcsupport | |
parent | Removed targets and configurations that are no longer functional (diff) | |
download | rtems-0139484fbdc976ffe07598d1284aad5eba3219be.tar.bz2 |
Patch from Wayne Bullaughey <wayne@wmi.com>. Comments follow:
I'm working on code to mount my host based file system on the base file
system (imfs) and have a suggestion for a change to eval.c in the
c/src/lib/libc directory of the 8/20/1999 snapshot. The current version
does not test the result value returned from the evalpath callback (line 47)
in the case where follow_link is true. Attached is my suggested change.
Without this test the node_type callback may be called after evalpath
failed. node_type could set the type to some value other then
RTEMS_FILESYSTEM_HARD_LINK or RTEMS_FILESYSTEM_SYM_LINK but it seems cleaner
to add the check on result.
Diffstat (limited to 'c/src/exec/libcsupport')
-rw-r--r-- | c/src/exec/libcsupport/src/eval.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/c/src/exec/libcsupport/src/eval.c b/c/src/exec/libcsupport/src/eval.c index bf7dd1c126..db294fcf54 100644 --- a/c/src/exec/libcsupport/src/eval.c +++ b/c/src/exec/libcsupport/src/eval.c @@ -51,7 +51,7 @@ int rtems_filesystem_evaluate_path( * not. */ - if ( follow_link ) { + if ( (result == 0) && follow_link ) { if ( !pathloc->ops->node_type ) set_errno_and_return_minus_one( ENOTSUP ); |