From c010ce52740ca65bee86b29a772afd28a8f9d3aa Mon Sep 17 00:00:00 2001 From: TevinWang Date: Sun, 28 Apr 2024 18:52:01 -0400 Subject: [PATCH] Set console width constant --- common/common.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/common/common.cpp b/common/common.cpp index 1d8db119e..b8d1b99cb 100644 --- a/common/common.cpp +++ b/common/common.cpp @@ -70,6 +70,7 @@ #define LLAMA_CURL_MAX_HEADER_LENGTH 256 #define LLAMA_PROGRESS_UPDATE_INTERVAL 1 #define LLAMA_PROGRESS_PERCENTAGE_WIDTH 10 +#define LLAMA_DEFAULT_CONSOLE_WIDTH 80 #endif // LLAMA_USE_CURL using json = nlohmann::ordered_json; @@ -1907,7 +1908,7 @@ static int get_console_width() { ioctl(STDOUT_FILENO, TIOCGWINSZ, &ws); return ws.ws_col; #else - return 80; // Default value + return LLAMA_DEFAULT_CONSOLE_WIDTH; // Default value #endif }