Bug fix to make sure Cantera compiles without VCSnonideal

This commit is contained in:
Harry Moffat 2007-12-19 22:55:45 +00:00
parent 45c65a18f9
commit c82624b1ca

View file

@ -106,8 +106,7 @@ namespace Cantera {
int retn = -1;
int nAttempts = 0;
int retnSub = 0;
bool estimateEquil = false;
int printLvlSub = 0;
if (loglevel > 0) {
beginLogGroup("equilibrate", loglevel);
@ -126,6 +125,9 @@ namespace Cantera {
}
while (redo) {
if (solver >= 2) {
#ifdef WITH_VCSNONIDEAL
int printLvlSub = 0;
bool estimateEquil = false;
m = new MultiPhase;
try {
m->addPhase(&s, 1.0);
@ -154,6 +156,10 @@ namespace Cantera {
throw err;
}
}
#else
throw CanteraError("equilibrate",
"VCSNonIdeal solver called, but not compiled");
#endif
} else if (solver == 1) {
m = new MultiPhase;
try {