]> ruin.nu Git - popboot.git/blobdiff - planner.cpp
no point in continuing if there are no more preconditions to satisfy
[popboot.git] / 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;