From c25b28c67429ffeb3f6dd0d82320fda311792b62 Mon Sep 17 00:00:00 2001 From: Gordon Sim Date: Tue, 11 Nov 2008 19:08:19 +0000 Subject: handle case where doOutput call causes last task to be removed. git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@713114 13f79535-47bb-0310-9956-ffa450edef68 --- cpp/src/qpid/sys/AggregateOutput.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'cpp/src/qpid/sys/AggregateOutput.cpp') diff --git a/cpp/src/qpid/sys/AggregateOutput.cpp b/cpp/src/qpid/sys/AggregateOutput.cpp index d2c4b7185e..849e2bacfb 100644 --- a/cpp/src/qpid/sys/AggregateOutput.cpp +++ b/cpp/src/qpid/sys/AggregateOutput.cpp @@ -47,6 +47,7 @@ bool AggregateOutput::doOutput() //loop until a task generated some output while (!result) { result = tasks[next++]->doOutput(); + if (tasks.empty()) break; if (next >= tasks.size()) next = next % tasks.size(); if (start == next) break; } -- cgit v1.2.1