mirror of
https://github.com/ggerganov/llama.cpp.git
synced 2025-01-15 06:40:45 +01:00
vulkan : fix free of stack addr in llama_buffer
This commit is contained in:
parent
f58f581ca8
commit
2d2c76acc4
@ -765,8 +765,10 @@ struct llama_buffer {
|
|||||||
~llama_buffer() {
|
~llama_buffer() {
|
||||||
if (data) {
|
if (data) {
|
||||||
#ifdef GGML_USE_KOMPUTE
|
#ifdef GGML_USE_KOMPUTE
|
||||||
if (ggml_vk_has_device()) {
|
if (memory.data) {
|
||||||
ggml_vk_free_memory(memory);
|
if (ggml_vk_has_device()) {
|
||||||
|
ggml_vk_free_memory(memory);
|
||||||
|
}
|
||||||
data = NULL;
|
data = NULL;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user