db/Plugin: use std::unique_ptr<> to manage Database pointers

This commit is contained in:
Max Kellermann
2019-02-20 20:32:11 +01:00
parent 2125e3ed57
commit 6c28adbcd2
15 changed files with 93 additions and 73 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2003-2018 The Music Player Daemon Project
* Copyright 2003-2019 The Music Player Daemon Project
* http://www.musicpd.org
*
* This program is free software; you can redistribute it and/or modify
@@ -20,12 +20,11 @@
#ifndef MPD_DATABASE_GLUE_HXX
#define MPD_DATABASE_GLUE_HXX
#include "util/Compiler.h"
#include "Ptr.hxx"
struct ConfigBlock;
class EventLoop;
class DatabaseListener;
class Database;
/**
* Initialize the database library.
@@ -34,7 +33,7 @@ class Database;
*
* @param block the database configuration block
*/
Database *
DatabasePtr
DatabaseGlobalInit(EventLoop &main_event_loop,
EventLoop &io_event_loop,
DatabaseListener &listener,