William Morgan <[email protected]> writes:
> Reformatted excerpts from William Morgan's message of 2009-06-24:
> > sup-sync crashes for me fairly systematically with this error:
> > 
> > ./lib/sup/xapian_index.rb:404:in `sortable_serialise': Expected argument 0 
> > of
> > type double, but got Fixnum 51767811298 (TypeError)
> 
> This turns out to be due to dates being far in the future (e.g. on spam
> messages). I'm using the attached patch, which is pretty much a hack, to
> force them to be between 1969 and 2038. Better solutions welcome. (I
> haven't committed this.)

The error you get here is actually a bug in SWIG (http://www.swig.org/).  Xapian
uses SWIG to generate the wrappers for Ruby.

The code SWIG currently uses to convert a parameter when a C/C++ function
takes a double doesn't handle a "fixnum" which is larger than MAXINT.  I've
just applied a fix to SWIG SVN:

http://swig.svn.sourceforge.net/viewvc/swig?view=rev&revision=11320

I'll make sure this fix makes it into the next Xapian release (which will be
1.0.14).

Cheers,
    Olly

_______________________________________________
sup-talk mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/sup-talk

Reply via email to