Skip to content

Commit 770462a

Browse files
committed
revert usage of GGML_ASSERT
1 parent 8941264 commit 770462a

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

examples/server/server.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1837,8 +1837,10 @@ struct server_context {
18371837
if (slot.ga_n == 1) {
18381838
if (slot.is_processing() && (int) system_tokens.size() + slot.n_past >= slot.n_ctx - 1) {
18391839
if (!params.ctx_shift) {
1840+
// this check is redundant (for good)
18401841
// we should never get here, because generation should already stopped in process_token()
1841-
GGML_ASSERT(false && "context shifting is disabled");
1842+
slot.release();
1843+
send_error(slot, "context shift is disabled", ERROR_TYPE_SERVER);
18421844
continue;
18431845
}
18441846

0 commit comments

Comments
 (0)