提交 1da45959 编写于 作者: G groot

invalid topk


Former-commit-id: a353f66e8f0503030713d9834a0bbaf726ca0001
上级 fa8c1b12
......@@ -513,7 +513,7 @@ ServerError SearchVectorTaskBase::OnExecute() {
return SetError(res, "Invalid table name: " + table_name_);
}
if(top_k_ <= 0) {
if(top_k_ <= 0 || top_k_ > 1024) {
return SetError(SERVER_INVALID_TOPK, "Invalid topk: " + std::to_string(top_k_));
}
if(record_array_.empty()) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册