diff options
author | John Wiegley <johnw@newartisans.com> | 2004-08-19 02:30:56 -0400 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2004-08-19 02:30:56 -0400 |
commit | f62a4906d1a8886fa086f5bd6a41b8597a31b1d4 (patch) | |
tree | aaa5438556cce06457a1493fb6bfdc1e29ebfe68 /textual.cc | |
parent | 41604e0ea65cb342aa05074bf39bbbc832c4c86a (diff) | |
download | fork-ledger-f62a4906d1a8886fa086f5bd6a41b8597a31b1d4.tar.gz fork-ledger-f62a4906d1a8886fa086f5bd6a41b8597a31b1d4.tar.bz2 fork-ledger-f62a4906d1a8886fa086f5bd6a41b8597a31b1d4.zip |
fix to textual parsing, and a bit of reconstruction in main.cc
Diffstat (limited to 'textual.cc')
-rw-r--r-- | textual.cc | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -110,6 +110,10 @@ transaction_t * parse_transaction(std::istream& in, account_t * account, in.getline(line, MAX_LINE); linenum++; + // Skip a possible blank line + if (*skip_ws(line) == '\0') + return NULL; + return parse_transaction_text(line, account, entry); } @@ -321,8 +325,7 @@ unsigned int parse_textual_journal(std::istream& in, journal_t * journal, if (peek_next_nonws(in) != '\n') { in.getline(line, MAX_LINE); linenum++; - throw parse_error(path, linenum, - "Ignoring entry beginning with whitespace"); + throw parse_error(path, linenum, "Line begins with whitespace"); } // fall through... |