[hackers] [scc] [cc2] Clean arena pointer after freeing memory || Roberto E. Vargas Caballero

From: <git_AT_suckless.org>
Date: Fri, 15 Apr 2016 18:37:49 +0200 (CEST)

commit edbfa2582bdfb774a8be7766e988172802614c5b
Author: Roberto E. Vargas Caballero <Roberto E. Vargas Caballero>
AuthorDate: Fri Apr 15 01:06:08 2016 +0200
Commit: Roberto E. Vargas Caballero <Roberto E. Vargas Caballero>
CommitDate: Fri Apr 15 01:06:08 2016 +0200

    [cc2] Clean arena pointer after freeing memory
    
    This mistake generated an invalid access in the second function

diff --git a/cc2/node.c b/cc2/node.c
index c85d347..f642fb3 100644
--- a/cc2/node.c
+++ b/cc2/node.c
_AT_@ -70,6 +70,7 @@ cleannodes(void)
                 free(ap->mem);
                 free(ap);
         }
+ arena = NULL;
 }
 
 void
Received on Fri Apr 15 2016 - 18:37:49 CEST

This archive was generated by hypermail 2.3.0 : Fri Apr 15 2016 - 18:48:25 CEST