diff options
author | Miklos Szeredi <miklos@szeredi.hu> | 2005-09-14 15:20:26 +0000 |
---|---|---|
committer | Miklos Szeredi <miklos@szeredi.hu> | 2005-09-14 15:20:26 +0000 |
commit | 7e7530d1b1661a0a6f7acc94129d6bf61206c82d (patch) | |
tree | 97961eb2cdf3bd9961e35758440359a8d1ca86bf /lib/fuse_loop_mt.c | |
parent | 644cd6ef226a59bd6560fde3812e5c9159bdebad (diff) |
fix
Diffstat (limited to 'lib/fuse_loop_mt.c')
-rw-r--r-- | lib/fuse_loop_mt.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/fuse_loop_mt.c b/lib/fuse_loop_mt.c index 478aae7..c0828f7 100644 --- a/lib/fuse_loop_mt.c +++ b/lib/fuse_loop_mt.c @@ -68,6 +68,7 @@ static void *do_work(void *data) return NULL; } + pthread_cleanup_push(free, buf); pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, NULL); pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, NULL); @@ -99,6 +100,7 @@ static void *do_work(void *data) pthread_mutex_unlock(&w->lock); fuse_session_process(w->se, buf, res, w->ch); } + pthread_cleanup_pop(1); /* Wait for cancellation */ if (!is_mainthread) |