Re: disconnect (was: 0.16.2 tomorrow)
Lukas Kahwe Smith <[email protected]>
| Newsgroups | gmane.comp.php.pear.liveuser |
|---|---|
| Message-ID | <[email protected]> |
Lukas Smith wrote: > Lukas Smith wrote: > >> Benedikt Laube wrote: >> >>> Hi Lukas, >>> >>> I found a workaround. It seems that LU does something with the db >>> object. Instantiating the db object *after* the LU object in a page >>> fixes the problem for me. >>> >>> If you have a more elegant solution, pls let me know! >> >> >> >> Hmm .. might be some reference issue. > > > I looked at the code some more. When loging out LiveUser calls the > disconnect() method. This method disconnects all ressources that > LiveUser opened. Since you pass in a dsn string, LiveUser determines it > needs to close the database connection. PEAR DB is kinda stupid since it > is then unable to reconnect ondemand anymore. MDB/MDB2 create a > connection ondemand. However we have the same problem with the XML and > other containers, so I will disable the disconnect method call for now > in logout(). ok this was kinda stupid. my observation was totaly wrong and this is likely the reason for bug #4928. actually login() will always create the necessary instances so disconnect() can be reenabled. now i am still unsure what is causing your issue, could you open a bug report, so i dont forget getting to the source of this .. could you also include your old calling order as a simple sample script? regards, Lukas