dataset is called 'material', not 'materialpoint'
avoid infinite loop in case it is not found
This commit is contained in:
parent
0cbb419b26
commit
cfeec53178
|
@ -366,9 +366,8 @@ subroutine readVTR(grid,geomSize,origin,microstructure)
|
||||||
gotCellData = .true.
|
gotCellData = .true.
|
||||||
startPos = endPos + 2_pI64
|
startPos = endPos + 2_pI64
|
||||||
do while (index(fileContent(startPos:endPos),'</CellData>',kind=pI64) == 0_pI64)
|
do while (index(fileContent(startPos:endPos),'</CellData>',kind=pI64) == 0_pI64)
|
||||||
endPos = startPos + index(fileContent(startPos:),IO_EOL,kind=pI64) - 2_pI64
|
|
||||||
if(index(fileContent(startPos:endPos),'<DataArray',kind=pI64) /= 0_pI64 .and. &
|
if(index(fileContent(startPos:endPos),'<DataArray',kind=pI64) /= 0_pI64 .and. &
|
||||||
getXMLValue(fileContent(startPos:endPos),'Name') == 'materialpoint' ) then
|
getXMLValue(fileContent(startPos:endPos),'Name') == 'material' ) then
|
||||||
|
|
||||||
if(getXMLValue(fileContent(startPos:endPos),'format') /= 'binary') &
|
if(getXMLValue(fileContent(startPos:endPos),'format') /= 'binary') &
|
||||||
call IO_error(error_ID = 844, ext_msg='format (materialpoint)')
|
call IO_error(error_ID = 844, ext_msg='format (materialpoint)')
|
||||||
|
@ -381,6 +380,7 @@ subroutine readVTR(grid,geomSize,origin,microstructure)
|
||||||
exit
|
exit
|
||||||
endif
|
endif
|
||||||
startPos = endPos + 2_pI64
|
startPos = endPos + 2_pI64
|
||||||
|
endPos = startPos + index(fileContent(startPos:),IO_EOL,kind=pI64) - 2_pI64
|
||||||
enddo
|
enddo
|
||||||
elseif(index(fileContent(startPos:endPos),'<Coordinates>',kind=pI64) /= 0_pI64) then
|
elseif(index(fileContent(startPos:endPos),'<Coordinates>',kind=pI64) /= 0_pI64) then
|
||||||
gotCoordinates = .true.
|
gotCoordinates = .true.
|
||||||
|
|
Loading…
Reference in New Issue