From 3a494bb11f0a2f449e4848fd17c2ee603bb2367e Mon Sep 17 00:00:00 2001 From: Adam Dickmeiss Date: Sat, 18 Oct 2008 13:50:48 +0200 Subject: [PATCH] Fixed memory leak (setname in ZOOM_resultset) --- src/zoom-c.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/zoom-c.c b/src/zoom-c.c index 1a3cf7a..2c12c6a 100644 --- a/src/zoom-c.c +++ b/src/zoom-c.c @@ -1480,7 +1480,8 @@ static zoom_ret ZOOM_connection_srw_send_search(ZOOM_connection c) { case ZOOM_TASK_SEARCH: resultset = c->tasks->u.search.resultset; - resultset->setname = xstrdup("default"); + if (!resultset->setname) + resultset->setname = xstrdup("default"); ZOOM_options_set(resultset->options, "setname", resultset->setname); start = &c->tasks->u.search.start; count = &c->tasks->u.search.count; -- 1.7.10.4