    # File lib/rbot/ircbot.rb, line 1153
      def restart(message=nil)
        message = "restarting, back in #{@config['server.reconnect_wait']}..." if (!message || message.empty?)
        shutdown(message)
        sleep @config['server.reconnect_wait']
        begin
          # now we re-exec
          # Note, this fails on Windows
          debug "going to exec #{$0} #{@argv.inspect} from #{@run_dir}"
          log_session_end
          Dir.chdir(@run_dir)
          exec($0, *@argv)
        rescue Errno::ENOENT
          log_session_end
          exec("ruby", *(@argv.unshift $0))
        rescue Exception => e
          $interrupted += 1
          raise e
        end
      end