From f3b182ca8002e2fe604a2c93c7e3cde84179be56 Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Wed, 16 Jul 2008 03:54:50 -0400 Subject: Patch from Nathan Jones so that trailing whitespace after account names in a transaction with no amount is not parsed as a special name. Fixes #3. --- textual.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/textual.cc b/textual.cc index 4e899eea..17f08852 100644 --- a/textual.cc +++ b/textual.cc @@ -139,7 +139,8 @@ transaction_t * parse_transaction(char * line, account_t * account, while (! in.eof()) { in.get(p); if (in.eof() || (std::isspace(p) && - (p == '\t' || std::isspace(in.peek())))) + (p == '\t' || in.peek() == EOF || + std::isspace(in.peek())))) break; account_end++; } -- cgit v1.2.3