This is an archive of the discontinued LLVM Phabricator instance.

[clangd] Shutdown cleanly on signals.
ClosedPublic

Authored by sammccall on Nov 25 2019, 10:51 AM.

Details

Summary

This avoids leaking PCH files if editors don't use the LSP shutdown protocol.

This is one fix for https://github.com/clangd/clangd/issues/209
(Though I think we should *also* be unlinking the files)

Diff Detail

Unit TestsFailed

Event Timeline

sammccall created this revision.Nov 25 2019, 10:51 AM
Herald added a project: Restricted Project. · View Herald Transcript

Build result: fail - 60239 tests passed, 1 failed and 732 were skipped.

failed: Clangd.Clangd/exit-signal.test

Log files: console-log.txt, CMakeCache.txt

Don't require temp file to already exist!

kadircet accepted this revision.Nov 26 2019, 12:42 AM

Thanks, LGTM!

This revision is now accepted and ready to land.Nov 26 2019, 12:42 AM

Build result: fail - 60239 tests passed, 1 failed and 732 were skipped.

failed: Clangd.Clangd/exit-signal.test

Log files: console-log.txt, CMakeCache.txt

sammccall updated this revision to Diff 231014.Nov 26 2019, 1:15 AM

Don't close the input stream early.

Build result: pass - 60240 tests passed, 0 failed and 732 were skipped.

Log files: console-log.txt, CMakeCache.txt

This revision was automatically updated to reflect the committed changes.