Skip to content

Commit 5fce5f9

Browse files
authored
kv-cache : fix use-after-move of defrag info (#14189)
ggml-ci
1 parent 9ae4143 commit 5fce5f9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/llama-kv-cache-unified.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1739,7 +1739,7 @@ llama_kv_cache_unified_state::llama_kv_cache_unified_state(
17391739
llama_context * lctx,
17401740
bool do_shift,
17411741
defrag_info dinfo) : status(LLAMA_MEMORY_STATUS_SUCCESS), kv(kv), lctx(lctx), do_shift(do_shift), dinfo(std::move(dinfo)) {
1742-
if (!do_shift && dinfo.empty()) {
1742+
if (!do_shift && this->dinfo.empty()) {
17431743
status = LLAMA_MEMORY_STATUS_NO_UPDATE;
17441744
}
17451745
}

0 commit comments

Comments
 (0)