Re: [sqlite] Help with Backup API please

2017-02-08 Thread Barry
Ok. My bad for singling out SQLite, I should have rather mentioned that the problem exists with all memory allocation routines (malloc/free or new/delete), at least on windows. A workaround is to pass around allocator / deallocator function pointers with any data structure which contains pointers

Re: [sqlite] Help with Backup API please

2017-02-08 Thread Richard Hipp
On 2/8/17, Barry Smith wrote: > > I believe SQLite doesn't use the standard memory allocation routines, but > instead has its own routines. SQLite has its on memory allocation routines (if you use the right compile-time and start-time options) but it uses system

Re: [sqlite] Help with Backup API please

2017-02-08 Thread Barry Smith
Hi Brett, I believe SQLite doesn't use the standard memory allocation routines, but instead has its own routines. These (might) use global variables. If each module of your application statically links to the SQLite source rather than having SQLite in a common DLL, then each module will have

Re: [sqlite] Help with Backup API please

2017-02-08 Thread Clemens Ladisch
Brett Goodman wrote: > When I call sqlite3_backup_init it throws this error: _/"library /__/ > /__/routine called out of sequence"/_. To you get an error code, or an exception? In the first case, try calling sqlite3_errmsg(). The documentation says: | A call to sqlite3_backup_init() will fail,

[sqlite] Help with Backup API please

2017-02-08 Thread Brett Goodman
Hello Sqlite users. I have a problem I can't solve. I have a C++ DLL project in which I compile the Sqlite amalgamation code. The purpose is to wrap the key Sqlite functions with exported functions I can call from another C++ COM DLL. I'm using VS2003 for this because its part of a legacy