On 23.10.2006, at 06:32, David Balmain wrote:

> Hi Andy,
>
> This works for me so I'll need a little more info to solve the
> problem. First, try running this:
>
>     [...]
>
>     i = Ferret::I.new(:analyzer => Analyzer.new)
>
>     i << "A sentence to analyze"
>
>     puts i.search("analyze")
>
> If that works, try and track down where in your code ferret is seg- 
> faulting.

Dave,

thanks for the hint. I was using the add_document method instead of  
<< to add documents to the index. Changing the above code to

   i = Ferret::I.new()

   i.addDocument("A sentence to analyze", Analyzer.new)

still works fine.

However, changing my original code to use the << method (and  
specifying the Analyzer with Index.new) solves the problem. I didn't  
manage to distill a concise test case from my code to reproduce the  
segfault. And hey, why bother, it works just fine now :)

Thanks again,
Andy
  
_______________________________________________
Ferret-talk mailing list
Ferret-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/ferret-talk

Reply via email to