<p><b>duda</b> 2012-04-09 17:31:33 -0600 (Mon, 09 Apr 2012)</p><p>BRANCH COMMIT<br>
<br>
Adding additional checks on compatibility of IO decompositions to avoid false matches.<br>
<br>
<br>
M src/framework/mpas_io.F<br>
</p><hr noshade><pre><font color="gray">Modified: branches/omp_blocks/io/src/framework/mpas_io.F
===================================================================
--- branches/omp_blocks/io/src/framework/mpas_io.F        2012-04-09 21:41:04 UTC (rev 1763)
+++ branches/omp_blocks/io/src/framework/mpas_io.F        2012-04-09 23:31:33 UTC (rev 1764)
@@ -972,7 +972,19 @@
end if
end do
- ! Type and dimensions match... what about indices?
+ if (size(decomp_cursor % decomphandle % indices) /= size(indices)) then
+write(0,*) 'We do not have the same number of indices in this decomposition...'
+ decomp_cursor => decomp_cursor % next
+ cycle DECOMP_LOOP
+ end if
+
+ do i=1,size(decomp_cursor % decomphandle % indices)
+ if (indices(i) /= decomp_cursor % decomphandle % indices(i)) then
+write(0,*) 'One of the indices does not match... ', i
+ decomp_cursor => decomp_cursor % next
+ cycle DECOMP_LOOP
+ end if
+ end do
! OK, we have a match... just use this decomposition for the field and return
field_cursor % fieldhandle % decomp => decomp_cursor % decomphandle
</font>
</pre>