diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2013-06-18 14:14:43 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2013-06-21 10:26:11 +0200 |
commit | 9165a5b07d569d23443c286e5a2b2a26148a6526 (patch) | |
tree | 062ad86ee886c15c3a9cd285c7c5e891e2ea2a6b /cpukit/libfs/src/imfs | |
parent | libchip/serial: Fix warning (diff) | |
download | rtems-9165a5b07d569d23443c286e5a2b2a26148a6526.tar.bz2 |
IMFS: Fix reference count for debug enabled
Diffstat (limited to 'cpukit/libfs/src/imfs')
-rw-r--r-- | cpukit/libfs/src/imfs/imfs_initsupp.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/cpukit/libfs/src/imfs/imfs_initsupp.c b/cpukit/libfs/src/imfs/imfs_initsupp.c index a68fff178f..12826f79a2 100644 --- a/cpukit/libfs/src/imfs/imfs_initsupp.c +++ b/cpukit/libfs/src/imfs/imfs_initsupp.c @@ -130,10 +130,10 @@ void IMFS_node_free( const rtems_filesystem_location_info_t *loc ) { IMFS_jnode_t *node = loc->node_access; - if ( node->reference_count == 1 ) { + --node->reference_count; + + if ( node->reference_count == 0 ) { IMFS_node_destroy( node ); - } else { - --node->reference_count; } } |