mirror of
https://github.com/MaskRay/ccls.git
synced 2025-06-08 09:14:54 +00:00
Make message handler throw NotIndexed if not overdue
This completes the fix of "not indexed" errors, which was inadvertently omitted in a previous fix.
This commit is contained in:
parent
8b2dd97370
commit
4f5b013f83
@ -274,6 +274,8 @@ MessageHandler::FindOrFail(const std::string &path, ReplyOnce &reply,
|
|||||||
}
|
}
|
||||||
QueryFile *file = FindFile(path, out_file_id);
|
QueryFile *file = FindFile(path, out_file_id);
|
||||||
if (!file) {
|
if (!file) {
|
||||||
|
if (!overdue)
|
||||||
|
throw NotIndexed{path};
|
||||||
reply.Error(ErrorCode::InvalidRequest, "not indexed");
|
reply.Error(ErrorCode::InvalidRequest, "not indexed");
|
||||||
return {nullptr, nullptr};
|
return {nullptr, nullptr};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user