Fix pcl-3la.2: remove spurious fuse_loop_mt while-loop and exit(0)
fuse_loop_mt() already loops internally; wrapping it in an additional while loop caused repeated re-entry after normal exit. Also removes the exit(0) call in the shutdown path so fuse_destroy() and other cleanup run properly on shutdown. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
f3d1021590
commit
3686e6ed9b
|
|
@ -3651,21 +3651,13 @@ static void psync_fuse_thread() {
|
|||
}
|
||||
pthread_mutex_unlock(&start_mutex);
|
||||
pdbg_logf(D_NOTICE, "running fuse_loop_mt");
|
||||
|
||||
// Check shutdown flag periodically during FUSE loop
|
||||
while (!shutdown_requested) {
|
||||
fr = fuse_loop_mt(psync_fuse);
|
||||
if (fr != 0 || shutdown_requested) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
fr = fuse_loop_mt(psync_fuse);
|
||||
|
||||
if (shutdown_requested) {
|
||||
pdbg_logf(D_NOTICE, "shutdown requested, exiting fuse loop");
|
||||
pfs_do_stop();
|
||||
exit(0);
|
||||
}
|
||||
|
||||
|
||||
pdbg_logf(D_NOTICE, "fuse_loop_mt exited with code %d, running fuse_destroy", fr);
|
||||
pthread_mutex_lock(&start_mutex);
|
||||
fuse_destroy(psync_fuse);
|
||||
|
|
|
|||
Loading…
Reference in New Issue