util_exit.f 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. c*************************************************************************
  2. c UTIL_EXIT.F
  3. c*************************************************************************
  4. c Exits program
  5. c
  6. c Input:
  7. c iflg ==> status of exit
  8. c = 0 if normal exit
  9. c = 1 if exit because error
  10. c
  11. c Remarks:
  12. c Authors: Hal Levison
  13. c Date: 8/6/93
  14. c Last revision: MD : change calc. of rhil Apr. 25
  15. subroutine util_exit(iflg)
  16. include '../swift.inc'
  17. c... Inputs:
  18. integer iflg
  19. c-----
  20. c... Executable code
  21. write(*,*) ' '
  22. if(iflg.eq.0) then
  23. write(*,1000) VER_NUM
  24. 1000 format('Normal termination of SWIFT (version ',f3.1,')')
  25. else
  26. write(*,2000) VER_NUM
  27. 2000 format('Terminating SWIFT (version',f3.1,') due to ERROR!!! ')
  28. endif
  29. write(*,*) '----------------------------------------------------'
  30. stop
  31. end ! util_exit
  32. c---------------------------------------------------