[PATCH] D52420: [clangd] Fix crash if pending computations were active on exit

2018-09-25 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL343067: [clangd] Fix crash if pending computations were active on exit (authored by ibiryukov, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/

[PATCH] D52420: [clangd] Fix crash if pending computations were active on exit

2018-09-25 Thread Eric Liu via Phabricator via cfe-commits
ioeric accepted this revision. ioeric added a comment. This revision is now accepted and ready to land. lgtm Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D52420 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.l

[PATCH] D52420: [clangd] Fix crash if pending computations were active on exit

2018-09-24 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added inline comments. Comment at: clangd/ClangdLSPServer.cpp:483 + // Destroy ClangdServer to ensure all worker threads finish. + Server.reset(); ioeric wrote: > This woudn't work if `run()` is called multiple times. Maybe create a > `Server`

[PATCH] D52420: [clangd] Fix crash if pending computations were active on exit

2018-09-24 Thread Eric Liu via Phabricator via cfe-commits
ioeric added inline comments. Comment at: clangd/ClangdLSPServer.cpp:483 + // Destroy ClangdServer to ensure all worker threads finish. + Server.reset(); This woudn't work if `run()` is called multiple times. Maybe create a `Server` in each `run()`? Repos

[PATCH] D52420: [clangd] Fix crash if pending computations were active on exit

2018-09-24 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. ilya-biryukov added reviewers: sammccall, ioeric. Herald added subscribers: kadircet, arphaman, jkorous, MaskRay. Make sure JSONRPCDispatcher outlives the worker threads, they access its fields to remove the stored cancellations when Context dies. Repository: