mirror of https://gitlab.com/QEF/q-e.git
Safe lower bound for string check, or it may crash in phonon (phq_readin, line 488) if fildyn is too short
git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@8595 c92efa57-630b-4861-b058-cf58834340f0
This commit is contained in:
parent
7046a190ea
commit
e8df497cbc
|
@ -14,13 +14,14 @@ IMPLICIT NONE
|
|||
|
||||
CHARACTER(LEN=*), INTENT(INOUT) :: inp_string
|
||||
|
||||
INTEGER :: leng
|
||||
INTEGER :: leng, start
|
||||
CHARACTER(LEN=4) :: aux
|
||||
LOGICAL, EXTERNAL :: matches
|
||||
|
||||
has_xml=.FALSE.
|
||||
leng=LEN_TRIM(inp_string)
|
||||
aux=inp_string(leng-3:leng)
|
||||
start=MAX(leng-3,1)
|
||||
aux=inp_string(start:leng)
|
||||
|
||||
IF (matches(aux,'.xml').OR.matches(aux,'.XML')) THEN
|
||||
has_xml=.TRUE.
|
||||
|
|
Loading…
Reference in New Issue