summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README.textile2
-rw-r--r--lib/Makefile2
-rw-r--r--src/error.cc2
-rw-r--r--src/filters.cc13
-rw-r--r--src/filters.h2
-rw-r--r--src/query.cc4
-rw-r--r--src/times.cc3
7 files changed, 17 insertions, 11 deletions
diff --git a/README.textile b/README.textile
index 922515a5..b4192928 100644
--- a/README.textile
+++ b/README.textile
@@ -149,7 +149,7 @@ h2. Resources
Now that you're up and running, here are a few resources to keep in mind:
-|Home page|"http://www.newartisans.com/software/ledger.html":http://www.newartisans.com/software/ledger.html|
+|Home page|"http://ledger-cli.org":http://ledger-cli.org|
|IRC channel|"#ledger on irc.freenode.net":irc://irc.freenode.net/ledger|
|Mailing List / Forum|"http://groups.google.com/group/ledger-cli":http://groups.google.com/group/ledger-cli|
|GitHub project page|"http://github.com/jwiegley/ledger":http://github.com/jwiegley/ledger|
diff --git a/lib/Makefile b/lib/Makefile
index 06d4da93..e2d5dd2b 100644
--- a/lib/Makefile
+++ b/lib/Makefile
@@ -36,7 +36,7 @@ BOOST_TOOLSET = darwin
BOOST_DEFINES += define=_GLIBCXX_DEBUG=1
endif
#BOOST_FLAGS = --architecture=x86 --address_model=32_64
-BOOST_FLAGS = --toolset=$(BOOST_TOOLSET) \
+BOOST_FLAGS = toolset=$(BOOST_TOOLSET) \
--build-type=complete --layout=versioned \
$(BOOST_DEFINES)
BOOST_DIR = boost_$(BOOST_VERSION)-$(DIR_SUFFIX)
diff --git a/src/error.cc b/src/error.cc
index c6309702..02413ef6 100644
--- a/src/error.cc
+++ b/src/error.cc
@@ -90,7 +90,7 @@ string source_context(const path& file,
return _("<no source context>");
assert(len > 0);
- assert(len < 2048);
+ assert(len < 8192);
std::ostringstream out;
diff --git a/src/filters.cc b/src/filters.cc
index a39fc951..2a040029 100644
--- a/src/filters.cc
+++ b/src/filters.cc
@@ -1373,7 +1373,7 @@ inject_posts::inject_posts(post_handler_ptr handler,
account_t * master)
: item_handler<post_t>(handler)
{
- TRACE_CTOR(inject_posts, "post_handler_ptr, string");
+ TRACE_CTOR(inject_posts, "post_handler_ptr, string, account_t *");
scoped_array<char> buf(new char[tag_list.length() + 1]);
std::strcpy(buf.get(), tag_list.c_str());
@@ -1381,9 +1381,9 @@ inject_posts::inject_posts(post_handler_ptr handler,
for (char * q = std::strtok(buf.get(), ",");
q;
q = std::strtok(NULL, ",")) {
-
std::list<string> account_names;
split_string(q, ':', account_names);
+
account_t * account =
create_temp_account_from_path(account_names, temps, master);
account->add_flags(ACCOUNT_GENERATED);
@@ -1397,13 +1397,12 @@ void inject_posts::operator()(post_t& post)
{
foreach (tags_list_pair& pair, tags_list) {
optional<value_t> tag_value = post.get_tag(pair.first, false);
+ // When checking if the transaction has the tag, only inject once
+ // per transaction.
if (! tag_value &&
- pair.second.second.find(post.xact) == pair.second.second.end()) {
- // When checking if the transaction has the tag, only inject once
- // per transaction.
+ pair.second.second.find(post.xact) == pair.second.second.end() &&
+ (tag_value = post.xact->get_tag(pair.first)))
pair.second.second.insert(post.xact);
- tag_value = post.xact->get_tag(pair.first);
- }
if (tag_value) {
xact_t& xact = temps.copy_xact(*post.xact);
diff --git a/src/filters.h b/src/filters.h
index 2916857d..227245fb 100644
--- a/src/filters.h
+++ b/src/filters.h
@@ -97,6 +97,7 @@ public:
virtual void clear() {
posts_map.clear();
post_chain->clear();
+ item_handler<post_t>::clear();
}
};
@@ -365,6 +366,7 @@ public:
virtual void clear() {
temps.clear();
+ comms.clear();
last_xact = NULL;
item_handler<post_t>::clear();
diff --git a/src/query.cc b/src/query.cc
index 5480336c..2a29a1e7 100644
--- a/src/query.cc
+++ b/src/query.cc
@@ -536,11 +536,13 @@ query_t::parser_t::parse_query_expr(lexer_t::token_t::kind_t tok_context,
}
default:
- break;
+ goto done;
}
tok = lexer.peek_token();
}
+ done:
+ ;
}
return limiter;
diff --git a/src/times.cc b/src/times.cc
index 02e99e53..5249c11c 100644
--- a/src/times.cc
+++ b/src/times.cc
@@ -40,6 +40,9 @@ optional<datetime_t> epoch;
date_time::weekdays start_of_week = gregorian::Sunday;
//#define USE_BOOST_FACETS 1
+#if defined(USE_BOOST_FACETS)
+#error "Boost facets are not quite working yet"
+#endif
namespace {
template <typename T, typename InputFacetType, typename OutputFacetType>