Re: [sqlite] Issue with sqlite3_result_error inside aggregatefunction

2005-11-17 Thread Roger Binns
Thanks for the confirmation, so I'm not imagining things. Unfortunately, signaling errors from the step function causes a segmentation fault on my system (actually, I tested this only through the apsw Python wrapper, which indirectly sparked this thread). BTW I did fix apsw in the last release.

Re: [sqlite] Issue with sqlite3_result_error inside aggregatefunction

2005-11-16 Thread Florian Weimer
* Nathan Kurz: > On Wed, Nov 16, 2005 at 01:16:40PM +0100, Florian Weimer wrote: >> * D. Richard Hipp: >> >> > If an error occurs in a step function, record that fact in >> > the aggregate context. Then when the finalizer is called, >> > check the error flag in the context and call sqlite3_resul

Re: [sqlite] Issue with sqlite3_result_error inside aggregatefunction

2005-11-16 Thread Nathan Kurz
On Wed, Nov 16, 2005 at 01:16:40PM +0100, Florian Weimer wrote: > * D. Richard Hipp: > > > If an error occurs in a step function, record that fact in > > the aggregate context. Then when the finalizer is called, > > check the error flag in the context and call sqlite3_result_error > > at that poi

Re: [sqlite] Issue with sqlite3_result_error inside aggregatefunction

2005-11-16 Thread Florian Weimer
* D. Richard Hipp: > If an error occurs in a step function, record that fact in > the aggregate context. Then when the finalizer is called, > check the error flag in the context and call sqlite3_result_error > at that point if it is appropriate to do so. Does this really work? According to my e

Re: [sqlite] Issue with sqlite3_result_error inside aggregatefunction

2005-09-27 Thread D. Richard Hipp
On Tue, 2005-09-27 at 08:33 -0700, Roger Binns wrote: > > You should not call sqlite3_result_* from within the step > > function of an aggregate. Those routines may be called from > > within the finalizer function only. > > So what should I do if an error occurs? Since I am ultimately > running

Re: [sqlite] Issue with sqlite3_result_error inside aggregatefunction

2005-09-27 Thread Roger Binns
You should not call sqlite3_result_* from within the step function of an aggregate. Those routines may be called from within the finalizer function only. Could you add some sort of assertion so that it is caught if the functions are called? So what should I do if an error occurs? Since I am u