From 82304038a239bb833e88c9c342aae19ab5dda489 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dundar=20G=C3=B6c?= <gocdundar@gmail.com> Date: Sat, 26 Mar 2022 11:54:31 +0100 Subject: [PATCH] vim-patch:8.2.3943: compiler warning from gcc for uninitialized variable Problem: Compiler warning from gcc for uninitialized variable. Solution: Initialize variable. (closes vim/vim#9429) https://github.com/vim/vim/commit/491669701c72578f273db53e579d8a03a9deac0c --- src/nvim/diff.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nvim/diff.c b/src/nvim/diff.c index 1b8a9f41e9..a6bbe40999 100644 --- a/src/nvim/diff.c +++ b/src/nvim/diff.c @@ -1536,7 +1536,7 @@ static void diff_read(int idx_orig, int idx_new, diffio_T *dio) long off; int i; int notset = true; // block "*dp" not set yet - diffhunk_T *hunk; + diffhunk_T *hunk = NULL; // init to avoid gcc warning enum { DIFF_ED, DIFF_UNIFIED,