pgpool2.git / summary / log / commit / refs

commit    f82fcbe2e9301314b31e788ca79538ceae9a9e5d
Author:   Tatsuo Ishii <ishii@postgresql.org>
Commit:   Muhammad Usama <m.usama@gmail.com>
Date:     Tue Feb 25 06:43:43 2014 +0000

    Fix freeing NULL.
    
    free_systemdb_info() should check if the argument is NULL or not.
    Per Coverity 1111384.


src/libs/pcp/pcp.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/libs/pcp/pcp.c b/src/libs/pcp/pcp.c index 0fadbf59e..165466bf7 100644 --- a/src/libs/pcp/pcp.c +++ b/src/libs/pcp/pcp.c @@ -1068,6 +1068,9 @@ free_systemdb_info(SystemDBInfo * si) { int i, j; + if (si == NULL) + return; + free(si->hostname); free(si->user); free(si->password); [parent: ed519403562e]