aboutsummaryrefslogtreecommitdiff
path: root/src/ops.c
diff options
context:
space:
mode:
authorFelipe Oliveira Carvalho <felipekde@gmail.com>2014-02-27 16:13:11 -0300
committerThiago de Arruda <tpadilha84@gmail.com>2014-02-28 08:49:34 -0300
commit6eece5895e4f0c147ef21ebb4d170a54f8694182 (patch)
tree681674aa2f61f6044ab750e30ba41e7895005e1b /src/ops.c
parentef6933bd609e4f353f54fef8897cda217b295e34 (diff)
downloadrneovim-6eece5895e4f0c147ef21ebb4d170a54f8694182.tar.gz
rneovim-6eece5895e4f0c147ef21ebb4d170a54f8694182.tar.bz2
rneovim-6eece5895e4f0c147ef21ebb4d170a54f8694182.zip
Fix a 'garbage value' warning found by Clang's static analyzer
- Initialize lists in paragraph_start() - Remove two dead stores
Diffstat (limited to 'src/ops.c')
-rw-r--r--src/ops.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/ops.c b/src/ops.c
index 5fb256e30d..7c5f53757e 100644
--- a/src/ops.c
+++ b/src/ops.c
@@ -4096,11 +4096,11 @@ static int fmt_check_par(linenr_T lnum, int *leader_len, char_u **leader_flags,
*/
int paragraph_start(linenr_T lnum)
{
- char_u *p;
+ char_u *p;
int leader_len = 0; /* leader len of current line */
- char_u *leader_flags = NULL; /* flags for leader of current line */
- int next_leader_len; /* leader len of next line */
- char_u *next_leader_flags; /* flags for leader of next line */
+ char_u *leader_flags = NULL; /* flags for leader of current line */
+ int next_leader_len = 0; /* leader len of next line */
+ char_u *next_leader_flags = NULL; /* flags for leader of next line */
int do_comments; /* format comments */
if (lnum <= 1)