From 9062b574424503e9dd2c1773564f27826b7f41a4 Mon Sep 17 00:00:00 2001 From: Pixel Date: Wed, 8 Oct 2008 09:42:54 -0700 Subject: Obviously, the buffer has to be emptied AFTER we check it... --- lib/ReadJob.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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()) { -- cgit v1.2.3