dataset is called 'material', not 'materialpoint'

avoid infinite loop in case it is not found
This commit is contained in:
Martin Diehl 2020-09-23 21:08:42 +02:00
parent 0cbb419b26
commit cfeec53178
1 changed files with 2 additions and 2 deletions

View File

@ -366,9 +366,8 @@ subroutine readVTR(grid,geomSize,origin,microstructure)
gotCellData = .true.
startPos = endPos + 2_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. &
getXMLValue(fileContent(startPos:endPos),'Name') == 'materialpoint' ) then
getXMLValue(fileContent(startPos:endPos),'Name') == 'material' ) then
if(getXMLValue(fileContent(startPos:endPos),'format') /= 'binary') &
call IO_error(error_ID = 844, ext_msg='format (materialpoint)')
@ -381,6 +380,7 @@ subroutine readVTR(grid,geomSize,origin,microstructure)
exit
endif
startPos = endPos + 2_pI64
endPos = startPos + index(fileContent(startPos:),IO_EOL,kind=pI64) - 2_pI64
enddo
elseif(index(fileContent(startPos:endPos),'<Coordinates>',kind=pI64) /= 0_pI64) then
gotCoordinates = .true.