]> ruin.nu Git - popboot.git/commitdiff
no point in continuing if there are no more preconditions to satisfy
authorMichael Andreen <harv@ruin.nu>
Thu, 9 Jun 2005 14:22:33 +0000 (14:22 +0000)
committerMichael Andreen <harv@ruin.nu>
Sat, 26 Jan 2008 15:48:06 +0000 (16:48 +0100)
planner.cpp

index 9d845702f93f114d916feadf1acc9e421dbe930d..94d05494e10609181271c371b22895b12eaff4cb 100644 (file)
@@ -194,6 +194,9 @@ int Planner::cleanupExecution(){
                _goal.push_back(precond->first);
        }
 
+       if (goal.size() == 0)
+               exit(0);
+
        cout << "Unsatisfied preconditions so far: " << _goal.size() << ": ";
        copy(_goal.begin(), _goal.end(), ostream_iterator<string>(cout, " "));
        cout << endl;