diff options
author | Pixel <pixel@nobis-crew.org> | 2008-10-08 09:42:54 -0700 |
---|---|---|
committer | Pixel <pixel@nobis-crew.org> | 2008-10-08 09:42:54 -0700 |
commit | 9062b574424503e9dd2c1773564f27826b7f41a4 (patch) | |
tree | 3fe976cb704460d34d547fbcdfc505431b0902ca /lib/ReadJob.cc | |
parent | dd71dc00812064836776a0584101591400fe40a2 (diff) |
Obviously, the buffer has to be emptied AFTER we check it...
Diffstat (limited to 'lib/ReadJob.cc')
-rw-r--r-- | lib/ReadJob.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ReadJob.cc b/lib/ReadJob.cc index d444008..2c17e43 100644 --- a/lib/ReadJob.cc +++ b/lib/ReadJob.cc @@ -56,7 +56,6 @@ int ReadJob::Do() throw (GeneralException) { case 1: try { *d << buff << "\n"; - buff = ""; } catch (IOAgain e) { /***TODO*** Potential bug here: if the write was partial, we'd need to restart at a later position. */ @@ -66,6 +65,7 @@ int ReadJob::Do() throw (GeneralException) { } current = 0; if (regex->Match(buff)) return TASK_DONE; + buff = ""; } if (!s->IsClosed()) { |