      subroutine logit (string)

c write to stream 6 and designated log file if different

      character*(*) string
      logical opened

      common joblog

      if (joblog .ne. 6 .and. opened(joblog))
     2              call write (joblog, string)
      call write (6, string)
      return
      end
