Skip to content

Commit 7264596

Browse files
committed
null terminated seq_id list
1 parent 734f9e2 commit 7264596

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/llama.cpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -21199,7 +21199,8 @@ struct llama_batch_allocr {
2119921199
batch.n_seq_id = n_seq_id.data();
2120021200
}
2120121201
if (!batch.seq_id) {
21202-
seq_id.resize(batch.n_tokens);
21202+
seq_id.resize(batch.n_tokens + 1);
21203+
seq_id[batch.n_tokens] = NULL;
2120321204
for (int32_t i = 0; i < batch.n_tokens; i++) {
2120421205
seq_id[i] = seq_id_0.data();
2120521206
}

0 commit comments

Comments
 (0)