fixed a memory corruption bug stemming from not using an input iterator
This commit is contained in:
parent
bbcb49fed2
commit
de39574e89
1 changed files with 2 additions and 3 deletions
5
main.cc
5
main.cc
|
|
@ -14,6 +14,7 @@ using namespace ledger;
|
||||||
#include <fstream>
|
#include <fstream>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
#include <iterator>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <cstdlib>
|
#include <cstdlib>
|
||||||
#include <cstring>
|
#include <cstring>
|
||||||
|
|
@ -127,11 +128,9 @@ int main(int argc, char * argv[], char * envp[])
|
||||||
journal->sources.pop_front(); // remove cache_file
|
journal->sources.pop_front(); // remove cache_file
|
||||||
|
|
||||||
strings_list exceptions;
|
strings_list exceptions;
|
||||||
#if 0
|
|
||||||
std::set_difference(journal->sources.begin(), journal->sources.end(),
|
std::set_difference(journal->sources.begin(), journal->sources.end(),
|
||||||
config->files.begin(), config->files.end(),
|
config->files.begin(), config->files.end(),
|
||||||
exceptions.begin());
|
std::back_insert_iterator<strings_list>(exceptions));
|
||||||
#endif
|
|
||||||
|
|
||||||
if (entry_count == 0 || exceptions.size() > 0) {
|
if (entry_count == 0 || exceptions.size() > 0) {
|
||||||
journal.reset(new journal_t);
|
journal.reset(new journal_t);
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue