mirror of
https://github.com/ggml-org/llama.cpp.git
synced 2025-10-31 08:51:55 +00:00
fix double-free with --no-mmap
This commit is contained in:
@@ -650,8 +650,6 @@ struct llama_model_loader {
|
|||||||
// hint the OS that we don't need the data anymore
|
// hint the OS that we don't need the data anymore
|
||||||
// TODO: this may be a bad idea with devices that use the system memory (Metal?)
|
// TODO: this may be a bad idea with devices that use the system memory (Metal?)
|
||||||
mapping->discard(lt.data, lt.size);
|
mapping->discard(lt.data, lt.size);
|
||||||
} else {
|
|
||||||
free(lt.data);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user