summaryrefslogtreecommitdiff
path: root/src/item.cc
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2011-02-12 16:46:20 -0500
committerJohn Wiegley <johnw@newartisans.com>2011-02-12 17:55:55 -0500
commit1292eec17b317e5bd910760f74cf5849e272e23d (patch)
tree46141c3434460e4a7505e63991317b41ed82da21 /src/item.cc
parent61f11bab1791dc0d0a308750f26414662e6f654d (diff)
downloadfork-ledger-1292eec17b317e5bd910760f74cf5849e272e23d.tar.gz
fork-ledger-1292eec17b317e5bd910760f74cf5849e272e23d.tar.bz2
fork-ledger-1292eec17b317e5bd910760f74cf5849e272e23d.zip
Improved an assert
Diffstat (limited to 'src/item.cc')
-rw-r--r--src/item.cc5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/item.cc b/src/item.cc
index 9290ab2f..9a9ab833 100644
--- a/src/item.cc
+++ b/src/item.cc
@@ -529,11 +529,10 @@ string item_context(const item_t& item, const string& desc)
return empty_string;
std::streamoff len = item.pos->end_pos - item.pos->beg_pos;
- if (! len)
+ if (! (len > 0))
return empty_string;
- assert(len > 0);
- assert(len < 2048);
+ assert(len < 8192);
std::ostringstream out;