    # File lib/rubygems/server.rb, line 354
      def Marshal(req, res)
        @source_index.refresh!

        res['date'] = File.stat(@spec_dir).mtime

        index = Marshal.dump @source_index

        if req.request_method == 'HEAD' then
          res['content-length'] = index.length
          return
        end

        if req.path =~ /Z$/ then
          res['content-type'] = 'application/x-deflate'
          index = Gem.deflate index
        else
          res['content-type'] = 'application/octet-stream'
        end

        res.body << index
      end