X-Git-Url: http://git.indexdata.com/?p=idzebra-moved-to-github.git;a=blobdiff_plain;f=index%2Fretrieve.c;h=5b602ed19f532cb2353341994978c09651fcd517;hp=f5e6bb6834a8f6bf0de5445cbdb1ffd495112833;hb=0ef68e6e54cfd7a91a28ee3b1f305924ac34e787;hpb=55c58d19e99fdbc8f6035f9e88eea563970379e8 diff --git a/index/retrieve.c b/index/retrieve.c index f5e6bb6..5b602ed 100644 --- a/index/retrieve.c +++ b/index/retrieve.c @@ -249,7 +249,7 @@ int zebra_special_sort_fetch( else { char dst_buf[IT_MAX_WORD]; - char str[IT_MAX_WORD]; + WRBUF str = wrbuf_alloc(); const char *index_type; const char *db = 0; const char *string_index = 0; @@ -261,7 +261,7 @@ int zebra_special_sort_fetch( zebraExplain_lookup_ord(zh->reg->zei, ord, &index_type, &db, &string_index); - zebra_term_untrans(zh, index_type, dst_buf, str); + zebra_term_untrans(zh, index_type, dst_buf, wrbuf_cstr(str)); if (!oid_oidcmp(input_format, yaz_oid_recsyn_xml)) { @@ -285,6 +285,7 @@ int zebra_special_sort_fetch( wrbuf_printf(wrbuf, "%s %s %s\n", string_index, index_type, dst_buf); } + wrbuf_destroy(str); return 0; } }