summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--cpukit/ChangeLog6
-rw-r--r--cpukit/libfs/src/imfs/imfs_rmnod.c4
2 files changed, 10 insertions, 0 deletions
diff --git a/cpukit/ChangeLog b/cpukit/ChangeLog
index bb398bfb90..74a2920ee9 100644
--- a/cpukit/ChangeLog
+++ b/cpukit/ChangeLog
@@ -1,3 +1,9 @@
+2007-04-16 Joel Sherrill <joel@OARcorp.com>
+
+ PR 1240/filesystem
+ * libfs/src/imfs/imfs_rmnod.c: Fix link when removing a symlink. Memory
+ for filename was not being freed.
+
2007-04-16 Ralf Corsépius <ralf.corsepius@rtems.org>
* pppd/utils.c: Use uintptr_t instead of unsigned long.
diff --git a/cpukit/libfs/src/imfs/imfs_rmnod.c b/cpukit/libfs/src/imfs/imfs_rmnod.c
index d5e32378ad..f37cb6d23c 100644
--- a/cpukit/libfs/src/imfs/imfs_rmnod.c
+++ b/cpukit/libfs/src/imfs/imfs_rmnod.c
@@ -71,6 +71,10 @@ int IMFS_rmnod(
* Free memory associated with a memory file.
*/
+ if ( the_jnode->type == IMFS_SYM_LINK ) {
+ if ( the_jnode->info.sym_link.name )
+ free( the_jnode->info.sym_link.name );
+ }
free( the_jnode );
}