fixed hindexd.c::query_handler()