mirror of
https://github.com/uroni/urbackup_backend.git
synced 2025-10-26 11:36:50 +00:00
Free object in same thread
This commit is contained in:
parent
0890fb93d4
commit
9569266e3c
@ -55,6 +55,7 @@ public:
|
||||
~ScopedFreeObjRef()
|
||||
{
|
||||
delete ref;
|
||||
ref = NULL;
|
||||
}
|
||||
|
||||
private:
|
||||
|
||||
@ -158,7 +158,6 @@ ServerChannelThread::ServerChannelThread(ClientMain *client_main, const std::str
|
||||
|
||||
ServerChannelThread::~ServerChannelThread(void)
|
||||
{
|
||||
delete settings;
|
||||
Server->destroy(mutex);
|
||||
}
|
||||
|
||||
@ -168,6 +167,7 @@ void ServerChannelThread::operator()(void)
|
||||
lasttime=0;
|
||||
|
||||
settings=new ServerSettings(Server->getDatabase(Server->getThreadID(), URBACKUPDB_SERVER), clientid);
|
||||
ScopedFreeObjRef<ServerSettings*> settings_free(settings);
|
||||
|
||||
while(do_exit==false)
|
||||
{
|
||||
|
||||
Loading…
Reference in New Issue
Block a user