From f3a02a8e6bd94500ca434fefe065bed48e59b587 Mon Sep 17 00:00:00 2001 From: Martin Diehl Date: Thu, 9 May 2019 08:33:12 +0200 Subject: [PATCH] simplified --- src/DAMASK_interface.f90 | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/src/DAMASK_interface.f90 b/src/DAMASK_interface.f90 index d7e29865b..1eed9aab5 100644 --- a/src/DAMASK_interface.f90 +++ b/src/DAMASK_interface.f90 @@ -337,20 +337,16 @@ end subroutine setWorkingDirectory character(len=1024) function getSolverJobName() integer :: posExt,posSep - character(len=1024) :: tempString + posExt = scan(geometryFile,'.',back=.true.) + posSep = scan(geometryFile,'/',back=.true.) - tempString = geometryFile - posExt = scan(tempString,'.',back=.true.) - posSep = scan(tempString,'/',back=.true.) + getSolverJobName = geometryFile(posSep+1:posExt-1) - getSolverJobName = tempString(posSep+1:posExt-1) + posExt = scan(loadCaseFile,'.',back=.true.) + posSep = scan(loadCaseFile,'/',back=.true.) - tempString = loadCaseFile - posExt = scan(tempString,'.',back=.true.) - posSep = scan(tempString,'/',back=.true.) - - getSolverJobName = trim(getSolverJobName)//'_'//tempString(posSep+1:posExt-1) + getSolverJobName = trim(getSolverJobName)//'_'//loadCaseFile(posSep+1:posExt-1) end function getSolverJobName