From 861e9a66b576d28b2992c7c66799d08e847eee2c Mon Sep 17 00:00:00 2001 From: Pierangelo Masarati Date: Thu, 17 Jan 2002 19:33:48 +0000 Subject: [PATCH] fix uninitialized pointer (ITS#1538) --- servers/slapd/search.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/servers/slapd/search.c b/servers/slapd/search.c index c3a6acc34d..95a2789470 100644 --- a/servers/slapd/search.c +++ b/servers/slapd/search.c @@ -37,7 +37,7 @@ do_search( struct berval nbase = { 0, NULL }; struct berval fstr = { 0, NULL }; Filter *filter = NULL; - AttributeName *an; + AttributeName *an = NULL; ber_len_t siz, off, i; Backend *be; int rc; @@ -327,7 +327,7 @@ return_results:; if( fstr.bv_val != NULL) free( fstr.bv_val ); if( filter != NULL) filter_free( filter ); - free(an); + if( an != NULL ) free( an ); return rc; } -- 2.39.5