Edit

IABSD.fr/ports/textproc/patchutils/patches/patch-src_rediff_c

Branch :

  • Show log

    Commit

  • Author : sthen
    Date : 2020-07-20 12:07:17
    Hash : 3323dc74
    Message : update to patchutils-0.4.2

  • textproc/patchutils/patches/patch-src_rediff_c
  • $OpenBSD: patch-src_rediff_c,v 1.2 2020/07/20 12:07:17 sthen Exp $
    
    Avoid use of unitialized variable.  Fixes addhunk2 test with vm.malloc_conf=J.
    
    Index: src/rediff.c
    --- src/rediff.c.orig
    +++ src/rediff.c
    @@ -842,6 +842,7 @@ static int rediff (const char *original, const char *e
     		newhunk->filepos = pos;
     		newhunk->line_in_diff = linenum;
     		newhunk->num_lines = 0;
    +		newhunk->discard_offset = 0;
     
     		if (!strncmp (line, "--- ", 4)) {
     			struct file_info *info = xmalloc (sizeof *info);