From 7da8056607331f12b912b4a7c65592ac317c2ff4 Mon Sep 17 00:00:00 2001 From: Jan Edmund Lazo Date: Mon, 8 Mar 2021 23:29:30 -0500 Subject: vim-patch:8.2.2438: out of bounds compiler warning Problem: Out of bounds compiler warning. Solution: Increase the size of uf_name. https://github.com/vim/vim/commit/6a12e3342d84a1d754d793ed5019778bd60e7494 Do not set size of uf_name to avoid compiler warnings. Port only the comments. --- src/nvim/eval/typval.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/nvim/eval/typval.h b/src/nvim/eval/typval.h index 6fcb01aace..531b17cb59 100644 --- a/src/nvim/eval/typval.h +++ b/src/nvim/eval/typval.h @@ -341,8 +341,9 @@ struct ufunc { ///< used for s: variables int uf_refcount; ///< reference count, see func_name_refcount() funccall_T *uf_scoped; ///< l: local variables for closure - char_u uf_name[]; ///< Name of function; can start with 123_ - ///< ( is K_SPECIAL KS_EXTRA KE_SNR) + char_u uf_name[]; ///< Name of function (actual size equals name); + ///< can start with 123_ + ///< ( is K_SPECIAL KS_EXTRA KE_SNR) }; struct partial_S { -- cgit