Changeset 2302 for XIOS/dev


Ignore:
Timestamp:
02/23/22 14:57:02 (3 years ago)
Author:
jderouillat
Message:

Add an error to catch if read_access is not set on an input field (and so grid_ not allocated)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS/dev/dev_ym/XIOS_COUPLING/src/node/field.cpp

    r2264 r2302  
    14341434    } 
    14351435    else if (context->getServiceType()==CServicesManager::CLIENT) 
    1436       grid_->setContextClient(contextClient); 
     1436    { 
     1437      if (grid_) 
     1438        grid_->setContextClient(contextClient); 
     1439      else 
     1440        ERROR( "CField::setContextClient(contextClient)", 
     1441               << "Grid not defined for " << getId() 
     1442               << " (if field is an input field, set read_access to true)" 
     1443               ); 
     1444    } 
    14371445  } 
    14381446  CATCH_DUMP_ATTR 
Note: See TracChangeset for help on using the changeset viewer.