From 25835610e3ec53511a33d124326bd29bf0d99709 Mon Sep 17 00:00:00 2001 From: Karl-Johan Alm Date: Wed, 20 Nov 2024 19:03:32 +0900 Subject: [PATCH] add comment about extra null-term byte requirement --- include/llama.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/llama.h b/include/llama.h index 90791d5f5..cd592aa17 100644 --- a/include/llama.h +++ b/include/llama.h @@ -451,6 +451,7 @@ extern "C" { // Functions to access the model's GGUF metadata scalar values // - The functions return the length of the string on success, or -1 on failure // - The output string is always null-terminated and cleared on failure + // - When retrieving a string, an extra byte must be allocated to account for the null terminator // - GGUF array values are not supported by these functions // Get metadata value as a string by key name