From 842500144ee02c8b0a46d2cc43880f8d80998fa5 Mon Sep 17 00:00:00 2001 From: Xuan Son Nguyen Date: Sat, 4 May 2024 18:56:22 +0200 Subject: gguf-split: add --no-tensor-first-split (#7072) --- ggml.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ggml.c') diff --git a/ggml.c b/ggml.c index 74ecd592..82179a12 100644 --- a/ggml.c +++ b/ggml.c @@ -21139,7 +21139,7 @@ struct gguf_context * gguf_init_from_file(const char * fname, struct gguf_init_p } // read the tensor infos - { + if (ctx->header.n_tensors > 0) { ctx->infos = GGML_CALLOC(ctx->header.n_tensors, sizeof(struct gguf_tensor_info)); for (uint64_t i = 0; i < ctx->header.n_tensors; ++i) { -- cgit v1.2.3