Do not load the tables every time if they can be loaded from file

This commit is contained in:
Ian Bell
2015-04-06 23:20:43 -06:00
parent d5ebfffcfb
commit 219e0f031e

View File

@@ -677,14 +677,14 @@ class TabularBackend : public AbstractState
}
};
void check_tables(){
if (!tables_loaded){
try{
/// Try to load the tables if you can.
load_tables();
// Set the flag saying tables have been successfully loaded
tables_loaded = true;
}
catch(CoolProp::UnableToLoadError &){
/// Check directory size