This extract from the code of Guglielmo Pasa causes GNU Fortran 95 (GCC 4.1.0 20050401 (experimental)) to go into an infinite loop. Reducing the number of optional arguments or changing LEN(WHAT) to LEN=10, for example, stop the infinite loop. SUBROUTINE CQUERY(WHAT,OUI,NON) CHARACTER(LEN=*),INTENT(INOUT) :: WHAT CHARACTER(LEN=*),INTENT(IN),OPTIONAL :: OUI,NON INTEGER :: INFO CHARACTER(LEN(WHAT)) :: REP,Y0,N0 Y0=OUI N0=NON END SUBROUTINE CQUERY
*** This bug has been marked as a duplicate of 20821 ***