From 66fac03fae3af9dded964b01c89662819dbfc5c2 Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Thu, 16 Mar 2017 11:54:29 +0100 Subject: libio: Fix deadlock in location management Perform a context-dependent deferred location release to avoid a deadlock on the file system instance locks, for example during a chdir(). Update #2936. --- cpukit/libcsupport/src/sup_fs_eval_path.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cpukit/libcsupport/src/sup_fs_eval_path.c') diff --git a/cpukit/libcsupport/src/sup_fs_eval_path.c b/cpukit/libcsupport/src/sup_fs_eval_path.c index 459fa6bfc8..a05472f834 100644 --- a/cpukit/libcsupport/src/sup_fs_eval_path.c +++ b/cpukit/libcsupport/src/sup_fs_eval_path.c @@ -301,8 +301,8 @@ void rtems_filesystem_eval_path_cleanup( { free_location(&ctx->currentloc); rtems_filesystem_instance_unlock(&ctx->startloc->location); - rtems_filesystem_global_location_release(ctx->startloc); - rtems_filesystem_global_location_release(ctx->rootloc); + rtems_filesystem_global_location_release(ctx->startloc, false); + rtems_filesystem_global_location_release(ctx->rootloc, false); } void rtems_filesystem_eval_path_cleanup_with_parent( -- cgit v1.2.3