aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/diff.c
diff options
context:
space:
mode:
authorDundar Göc <gocdundar@gmail.com>2022-03-26 11:54:31 +0100
committerDundar Göc <gocdundar@gmail.com>2022-03-26 12:12:03 +0100
commit82304038a239bb833e88c9c342aae19ab5dda489 (patch)
treee04e689ca36f9395cb31923b39405818f3bb0f65 /src/nvim/diff.c
parentfb5587d2bede0cc091b92731b990bd2e394e9914 (diff)
downloadrneovim-82304038a239bb833e88c9c342aae19ab5dda489.tar.gz
rneovim-82304038a239bb833e88c9c342aae19ab5dda489.tar.bz2
rneovim-82304038a239bb833e88c9c342aae19ab5dda489.zip
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
Diffstat (limited to 'src/nvim/diff.c')
-rw-r--r--src/nvim/diff.c2
1 files changed, 1 insertions, 1 deletions
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,