Changeset 2638


Ignore:
Timestamp:
07/16/24 15:13:29 (2 months ago)
Author:
jderouillat
Message:

Fix read fields attributes for grid dimensions greater than 1, but without domain.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS2/trunk/src/io/nc4_data_input.cpp

    r2501 r2638  
    144144    // Verify the compatibility of dimension of declared grid and real grid in file 
    145145    int realGridDim = 1; 
    146     bool isUnstructuredGrid(true); 
     146    bool isUnstructuredGrid( (domainP.size()>0)  ); 
    147147    bool domainNotExplicitelyDefined(false); 
    148148    for (int idom=0;idom<domainP.size();idom++) 
     
    158158      } 
    159159    } 
    160     if ((domainNotExplicitelyDefined)||(domainP.size()==0)) 
    161     { 
    162       isUnstructuredGrid = ((gridDim < 2) ? false :  SuperClassWriter::isUnstructured(fieldId)); 
     160    if (domainNotExplicitelyDefined) 
     161    { 
     162      isUnstructuredGrid = SuperClassWriter::isUnstructured(fieldId); 
    163163    } 
    164164    std::map<StdString, StdSize> dimSizeMap = SuperClassWriter::getDimensions(&fieldId); 
Note: See TracChangeset for help on using the changeset viewer.