Ignore:
Timestamp:
11/05/18 13:57:52 (5 years ago)
Author:
oabramkina
Message:

Backporting r1578 and r1586 to dev, cleaning the code before merging it to XIOS 2.5.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS/dev/dev_olga/src/io/nc4_data_output.cpp

    r1571 r1589  
    166166           for (int idx = 0; idx < nbWritten; ++idx) 
    167167           { 
    168                   if (indexToWrite(idx) < 0) 
    169                   { 
    170               writtenLat(idx) = -1.;   // hole 
    171               writtenLon(idx) = -1.; 
    172                   } 
    173                   else 
    174                   { 
    175               writtenLat(idx) = domain->latvalue(indexToWrite(idx)); 
    176               writtenLon(idx) = domain->lonvalue(indexToWrite(idx)); 
    177                   } 
    178            } 
    179           
     168             if (indexToWrite(idx) < 0) 
     169             { 
     170               writtenLat(idx) = -1.;   // hole 
     171               writtenLon(idx) = -1.; 
     172             } 
     173             else 
     174             { 
     175               writtenLat(idx) = domain->latvalue(indexToWrite(idx)); 
     176               writtenLon(idx) = domain->lonvalue(indexToWrite(idx)); 
     177             } 
     178           } 
    180179 
    181180           if (domain->hasBounds) 
     
    999998           for (int idx = 0; idx < nbWritten; ++idx) 
    1000999           { 
    1001                   if (indexToWrite(idx) < 0) 
    1002               writtenArea(idx) = -1.; 
    1003                   else 
    1004                     writtenArea(idx) = domain->areavalue(indexToWrite(idx)); 
     1000             if (indexToWrite(idx) < 0) 
     1001               writtenArea(idx) = -1.; 
     1002             else 
     1003               writtenArea(idx) = domain->areavalue(indexToWrite(idx)); 
    10051004           } 
    10061005         } 
     
    13291328                      axis_bounds(0, i) = axis->bounds(0, int(indexToWrite(i))); 
    13301329                      axis_bounds(1, i) = axis->bounds(1, int(indexToWrite(i))); 
    1331  
    13321330                    } 
    13331331                  } 
Note: See TracChangeset for help on using the changeset viewer.