[AppDB] new fix for preferences
Paul van Schayck
polleke at gmail.com
Thu Jan 13 15:47:11 CST 2005
On Thu, 13 Jan 2005 14:43:49 -0500, Chris Morgan <chmorgan at charter.net> wrote:
> Good job guys. That was a tricky one to figure out.
Yes it was (all honor to Tony and Jonathan for finding it). The memory
alloc problems were caused by addmsg() calling itself recursively
trying to insert a message, failing, and trying to insert a message
again (trough query_error()).
And those failures were caused because the connection to mysql was
changed to use another database (the bugzilla db, hence the failure
just after using a bugzilla function). And that was caused because
although we defined a different connection resource internally the
same handle was used (as descriped by the PHP manual)
Now we are reselecting the database with each call to the query
functions. This is still not completely a clean solution. As this will
send an additional query to mysql with each query.
I will try something with Tony tomorrow to get it completely clean.
We also need to protect addmsg calling itself recursively. I was
thinking of checking if it send out the same message already and if so
Another solution would be to not use quer_appdb() but just
mysql_query(). What do you think?
More information about the wine-devel