mirror of
https://github.com/pi-hole/FTL.git
synced 2024-10-26 16:52:18 +02:00
Skip dbopen() altogether when database is already open
Signed-off-by: DL6ER <dl6er@dl6er.de>
This commit is contained in:
@@ -64,6 +64,14 @@ void dbclose(void)
|
||||
|
||||
bool dbopen(void)
|
||||
{
|
||||
// Skip subroutine altogether when database is already open
|
||||
if(FTL_db != NULL && db_avail)
|
||||
{
|
||||
if(config.debug & DEBUG_LOCKS)
|
||||
logg("Not locking database (already open)");
|
||||
return true;
|
||||
}
|
||||
|
||||
if(config.debug & DEBUG_LOCKS)
|
||||
logg("Locking database");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user