Store Replacement failure

Bill Moseley <[email protected]>
Newsgroups gmane.comp.gnu.aspell.devel
Message-ID <[email protected]>
Hi Kevin,

This is in regard to my Text::Aspell Perl module.

I have been receiving reports of aspell_speller_store_replacement()
failing in the test suite.  I can't reproduce the problem, but as I
support the Perl Text::Aspell module I need to try and resolve the
issue.

Yesterday I had someone report the problem on three different platforms
all running 0.50.5 and latest Perl and module code.  Yesterday I also
built from new sources and could not reproduced the problem.

So, my question to you is there anything
aspell_speller_store_replacement() does that might be dependent on the
current environment that I can test?

The only thing odd I can find in the bug reports sent to me is the
config reporting odd paths (like $HOME is not set correctly):

            per-conf:  .aspell.conf
       per-conf-path:  //.aspell.conf
            personal:  .aspell.en.pws
       personal-path:  //.aspell.en.pws
              prefix:  /usr/site/aspell-0.50.5
                repl:  .aspell.en.prepl
           repl-path:  //.aspell.en.prepl

I don't think that's related to the problem, though, as I can set a bad
$HOME on my machine and it still doesn't fail for me.

The perl code that fails is simply:

   $speller->store_replacement('foo', 'bar')
      or print $speller->errstr;

$speller->errstr comes from aspell_speller_error_message().  No error
message is returned on failure.

This store_replacement() call is the only test in the module that is
failing -- that is, the interface is working fine otherwise.



And the Perl xs interface is just a thin wrapper to the call:

int
store_replacement(self,word,replacement)
    Aspell_object *self
    char * word
    char * replacement
    CODE:
        self->lastError[0] = '\0';
        self->errnum = 0;

        if (!self->speller && !_create_speller(self) )
            XSRETURN_UNDEF;


        RETVAL = aspell_speller_store_replacement(self->speller, word, -1, replacement, -1);
        if ( !RETVAL )
        {
            self->errnum = aspell_speller_error_number( (const AspellSpeller *)self->speller );
            strncpy(self->lastError, (char*) aspell_speller_error_message(self->speller), MAX_ERRSTR_LEN);
            XSRETURN_UNDEF;
        }
    OUTPUT:
        RETVAL

Can you provide any ides where to look or what to have the people
reporting the bug try?



-- 
Bill Moseley
[email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.