src/gray_params.f90: handle file not found error
This commit is contained in:
parent
023facac6b
commit
1648a7878a
@ -166,7 +166,7 @@ contains
|
||||
integer, intent(in), optional :: unit
|
||||
|
||||
! local variables
|
||||
integer :: u
|
||||
integer :: u, iostat
|
||||
|
||||
if (present(unit)) then
|
||||
u=unit
|
||||
@ -174,6 +174,10 @@ contains
|
||||
u = get_free_unit()
|
||||
end if
|
||||
open(u,file=filenm,status='old',action='read',iostat=iostat)
|
||||
if (iostat>0) then
|
||||
print'(a)', 'gray_params file not found!'
|
||||
call EXIT(1)
|
||||
end if
|
||||
|
||||
! Raytracing
|
||||
! ========================================================================
|
||||
|
Loading…
Reference in New Issue
Block a user