mirror of
https://github.com/ggml-org/llama.cpp.git
synced 2026-07-21 10:15:53 +00:00
tests: export-graph-ops: exit gracefully when called w/o arguments (#25619)
Fixes a segfault when `test-export-graph-ops` is called without any arguments.
This commit is contained in:
@@ -152,6 +152,10 @@ int main(int argc, char ** argv) {
|
||||
init_result = common_init_from_params(params);
|
||||
|
||||
ctx = init_result->context();
|
||||
if (!ctx) {
|
||||
LOG_ERR("failed to initialize params\n");
|
||||
return 1;
|
||||
}
|
||||
} else {
|
||||
#ifdef LLAMA_HF_FETCH
|
||||
auto [hf_repo, hf_quant] = common_download_split_repo_tag(params.model.hf_repo);
|
||||
|
||||
Reference in New Issue
Block a user