Changeset 2310
- Timestamp:
- Jul 11, 2017 9:37:02 AM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SOURCE/parin.f90
r2304 r2310 25 25 ! ----------------- 26 26 ! $Id$ 27 ! Bugfix: re-arranged call for error messages for ENVPAR file 28 ! 29 ! 2304 2017-07-04 14:35:55Z suehring 27 30 ! Bugfix, enable restarts for child domain. 28 31 ! … … 348 351 IMPLICIT NONE 349 352 350 INTEGER(iwp) :: i !< 353 INTEGER(iwp) :: i !< 354 INTEGER(iwp) :: ioerr !< error flag for open/read/write 351 355 352 356 … … 446 450 !-- generated by mrun) 447 451 CALL location_message( 'reading environment parameters from ENVPAR', .FALSE. ) 448 OPEN ( 90, FILE='ENVPAR', STATUS='OLD', FORM='FORMATTED', ERR=30 ) 449 READ ( 90, envpar, ERR=31, END=32 ) 450 CLOSE ( 90 ) 452 453 OPEN ( 90, FILE='ENVPAR', STATUS='OLD', FORM='FORMATTED', IOSTAT=ioerr ) 454 455 IF ( ioerr /= 0 ) THEN 456 message_string = 'local file ENVPAR not found' // & 457 '&some variables for steering may not be properly set' 458 CALL message( 'parin', 'PA0276', 0, 1, 0, 6, 0 ) 459 ELSE 460 READ ( 90, envpar, IOSTAT=ioerr ) 461 IF ( ioerr < 0 ) THEN 462 message_string = 'no envpar-NAMELIST found in local file ' // & 463 'ENVPAR&some variables for steering may ' // & 464 'not be properly set' 465 CALL message( 'parin', 'PA0278', 0, 1, 0, 6, 0 ) 466 ELSEIF ( ioerr > 0 ) THEN 467 message_string = 'errors in local file ENVPAR' // & 468 '&some variables for steering may not be properly set' 469 CALL message( 'parin', 'PA0277', 0, 1, 0, 6, 0 ) 470 ENDIF 471 CLOSE ( 90 ) 472 ENDIF 473 451 474 CALL location_message( 'finished', .TRUE. ) 452 475 … … 686 709 CALL location_message( 'finished', .TRUE. ) 687 710 688 RETURN689 690 30 message_string = 'local file ENVPAR not found' // &691 '&some variables for steering may not be properly set'692 CALL message( 'parin', 'PA0276', 0, 1, 0, 6, 0 )693 RETURN694 695 31 message_string = 'errors in local file ENVPAR' // &696 '&some variables for steering may not be properly set'697 CALL message( 'parin', 'PA0277', 0, 1, 0, 6, 0 )698 RETURN699 700 32 message_string = 'no envpar-NAMELIST found in local file ENVPAR' // &701 '&some variables for steering may not be properly set'702 CALL message( 'parin', 'PA0278', 0, 1, 0, 6, 0 )703 704 711 END SUBROUTINE parin
Note: See TracChangeset
for help on using the changeset viewer.