projects
/
dcpomatic.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix test logging setup to actually work.
[dcpomatic.git]
/
src
/
lib
/
zipper.cc
diff --git
a/src/lib/zipper.cc
b/src/lib/zipper.cc
index d43b18ef0beba9ee86a64740defd64822d53b1b3..2c334dc947fe62c9f25c06d5b47856c623219e32 100644
(file)
--- a/
src/lib/zipper.cc
+++ b/
src/lib/zipper.cc
@@
-1,5
+1,5
@@
/*
/*
- Copyright (C) 2020 Carl Hetherington <cth@carlh.net>
+ Copyright (C) 2020
-2021
Carl Hetherington <cth@carlh.net>
This file is part of DCP-o-matic.
This file is part of DCP-o-matic.
@@
-18,6
+18,7
@@
*/
*/
+
#include "zipper.h"
#include "exceptions.h"
#include "dcpomatic_assert.h"
#include "zipper.h"
#include "exceptions.h"
#include "dcpomatic_assert.h"
@@
-25,9
+26,10
@@
#include <boost/filesystem.hpp>
#include <stdexcept>
#include <boost/filesystem.hpp>
#include <stdexcept>
+
using std::string;
using std::runtime_error;
using std::string;
using std::runtime_error;
-using
boost
::shared_ptr;
+using
std
::shared_ptr;
Zipper::Zipper (boost::filesystem::path file)
Zipper::Zipper (boost::filesystem::path file)
@@
-49,7
+51,7
@@
Zipper::add (string name, string content)
shared_ptr<string> copy(new string(content));
_store.push_back (copy);
shared_ptr<string> copy(new string(content));
_store.push_back (copy);
-
struct zip_source*
source = zip_source_buffer (_zip, copy->c_str(), copy->length(), 0);
+
auto
source = zip_source_buffer (_zip, copy->c_str(), copy->length(), 0);
if (!source) {
throw runtime_error ("could not create ZIP source");
}
if (!source) {
throw runtime_error ("could not create ZIP source");
}