From 4bb72ed3cb73fb1da74603268bc11a46d8ec7489 Mon Sep 17 00:00:00 2001 From: Adam Dickmeiss Date: Fri, 14 Oct 2011 11:50:31 +0000 Subject: [PATCH] Avoid OUTPUTFACETS of type SVt_NULL Fixes crash one some older versions of Perl. --- SimpleServer.xs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/SimpleServer.xs b/SimpleServer.xs index c2e88c8..93546f2 100644 --- a/SimpleServer.xs +++ b/SimpleServer.xs @@ -989,8 +989,9 @@ int bend_search(void *handle, bend_search_rr *rr) point = newSVsv(*temp); temp = hv_fetch(href, "OUTPUTFACETS", 12, 1); - f_SV_to_FacetList(*temp, &rr->search_info, rr->stream); - + if (SvTYPE(*temp) != SVt_NULL) + f_SV_to_FacetList(*temp, &rr->search_info, rr->stream); + hv_undef(href); av_undef(aref); -- 1.7.10.4