On 24 Mar 2011, at 3:06am, Zaryab M. Munir wrote:

> Also, I must mention that if I call a different callback function which 
> doesn't do many calloc() etc.  I don't see this error.

Very good diagnostic.

Can you compare your code with the C example on this page:

<http://www.sqlite.org/quickstart.html>

Before proceeding please make sure your own code checks the result codes of 
every SQLite operation you are calling just like the example does.

Then see if you can create the same error in that code, or make the error 
disappear from your own code.  If inserting a few 'calloc()' into the code on 
the web page creates your error, then I suspect some sort of memory-handling 
problem.  Unfortunately I am not a C expert and cannot help but perhaps someone 
else here can.

This assumes that exactly the code on that page doesn't generate the same error 
in your environment !

By the way, to whoever understands the code on the web page.  Why does one 
function simply check the return value as a boolean '( rc )' but the other 
function check by explicitly comparing with SQLITE_OK ?  I have no complaint 
about either, and using both does demonstrate that they are both okay, I just 
wonder if there is something there I am not seeing.

Simon.
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to