diff options
author | Max Kellermann <max@duempel.org> | 2013-01-29 23:26:51 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2013-01-29 23:26:51 +0100 |
commit | f5c0b0d3168d6c34010f86a4b6878b7181d10237 (patch) | |
tree | 50304ecc4ab8690c9283051268a393e87e3a9461 /src/ArchiveInternal.hxx | |
parent | ba51045d9e85b8e48afed629d6d87ac3338acd46 (diff) | |
download | mpd-f5c0b0d3168d6c34010f86a4b6878b7181d10237.tar.gz mpd-f5c0b0d3168d6c34010f86a4b6878b7181d10237.tar.xz mpd-f5c0b0d3168d6c34010f86a4b6878b7181d10237.zip |
ArchiveFile: convert to a class
Diffstat (limited to '')
-rw-r--r-- | src/ArchiveFile.hxx (renamed from src/ArchiveInternal.hxx) | 19 |
1 files changed, 8 insertions, 11 deletions
diff --git a/src/ArchiveInternal.hxx b/src/ArchiveFile.hxx index f0bf2e108..52e5a4910 100644 --- a/src/ArchiveInternal.hxx +++ b/src/ArchiveFile.hxx @@ -17,18 +17,15 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ -#ifndef MPD_ARCHIVE_INTERNAL_HXX -#define MPD_ARCHIVE_INTERNAL_HXX +#ifndef MPD_ARCHIVE_FILE_HXX +#define MPD_ARCHIVE_FILE_HXX -struct archive_file { - const struct archive_plugin *plugin; -}; +class ArchiveFile { +public: + const struct archive_plugin &plugin; -static inline void -archive_file_init(struct archive_file *archive_file, - const struct archive_plugin *plugin) -{ - archive_file->plugin = plugin; -} + ArchiveFile(const struct archive_plugin &_plugin) + :plugin(_plugin) {} +}; #endif |