(wrong string) ä-Ollila

From: <git_AT_suckless.org>
Date: Tue, 12 Apr 2016 07:47:10 +0200 (CEST)

commit a1db98fafab9e5f348a1a1e16564caad4fb59f52
Author: Pekka Jylhä-Ollila <pekka.jylha.ollila_AT_gmail.com>
AuthorDate: Tue Apr 12 07:46:13 2016 +0200
Commit: Roberto E. Vargas Caballero <roberto.vargas_AT_igrid-td.com>
CommitDate: Tue Apr 12 07:46:38 2016 +0200

    [cc2]Fix segmentation fault in writeout function
    
    This patch fixes a segfault when more than one function is
    defined in the IR input.

diff --git a/cc2/node.c b/cc2/node.c
index 4bfc353..ef91dce 100644
--- a/cc2/node.c
+++ b/cc2/node.c
_AT_@ -69,7 +69,7 @@ cleannodes(void)
         struct arena *ap, *next;
 
         for (ap = arena; ap; ap = next) {
- next = ap;
+ next = ap->next;
                 free(ap->mem);
                 free(ap);
         }
diff --git a/cc2/parser.c b/cc2/parser.c
index 39a777f..b036fbd 100644
--- a/cc2/parser.c
+++ b/cc2/parser.c
_AT_@ -629,6 +629,7 @@ parse(void)
         cleannodes(); /* remove code of previous function */
         popctx(); /* remove context of previous function */
         curfun = NULL;
+ endf = 0;
 
         while (!endf && nextline())
                 /* nothing */;
Received on Tue Apr 12 2016 - 07:47:10 CEST

This archive was generated by hypermail 2.3.0 : Tue Apr 12 2016 - 07:48:13 CEST