On Oct 4, 2007, at 10:10 AM, Joe Wilson wrote:

--- "Chad Leigh -- Shire.Net LLC" <[EMAIL PROTECTED]> wrote:
Program received signal SIGSEGV, Segmentation fault.
0x00000008006cdcae in sqlite3Fts2InitHashTable (db=0x50c000,
pHash=0x5119c0, zName=0x8006e3c0b "fts2_tokenizer") at ./ext/fts2/
fts2_tokenizer.c:356
356       if( rc!=SQLITE_OK
(gdb) p rc
$17 = 0
(gdb)

...
int sqlite3Fts2InitHashTable(
   sqlite3 *db,
   fts2Hash *pHash,
   const char *zName
){
   int rc = SQLITE_OK;
   void *p = (void *)pHash;
   const int any = SQLITE_ANY;
   char *zTest = 0;
   char *zTest2 = 0;

#ifdef SQLITE_TEST
   void *pdb = (void *)db;
   zTest = sqlite3_mprintf("%s_test", zName);
   zTest2 = sqlite3_mprintf("%s_internal_test", zName);
   if( !zTest || !zTest2 ){
     rc = SQLITE_NOMEM;
   }
#endif

   if( rc!=SQLITE_OK
    || (rc = sqlite3_create_function(db, zName, 1, any, p,
scalarFunc, 0, 0))
    || (rc = sqlite3_create_function(db, zName, 2, any, p,
scalarFunc, 0, 0))
#ifdef SQLITE_TEST
    || (rc = sqlite3_create_function(db, zTest, 2, any, p, testFunc,
0, 0))
    || (rc = sqlite3_create_function(db, zTest, 3, any, p, testFunc,
0, 0))
    || (rc = sqlite3_create_function(db, zTest2, 0, any, pdb,
intTestFunc, 0, 0))
#endif
   );

SQLITE_TEST is not set.

Further experimentation, by setting a breakpoint on
sqlite3_create_function(), shows that this does not seem to be called
as the breakpoint is not triggered. I am not sure what is going on here

It doesn't make a lot of sense.

I agree, but in what way do you mean it does not make sense?

How exactly did you build sqlite3?

Using the freebsd ports system. I edited the Makefile to force debugging on and add a CFLAGS with --g -O0 in that case.

Have you tried 3.5.1?


No. I've been using what is in the FreeBSD ports system (my last update of the ports was about 1 month ago).

Chad



-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------

Reply via email to