    # File lib/rack/urlmap.rb, line 43
        def call(env)
          path = env[PATH_INFO]
          script_name = env['SCRIPT_NAME']
          hHost = env['HTTP_HOST']
          sName = env['SERVER_NAME']
          sPort = env['SERVER_PORT']

          @mapping.each do |host, location, match, app|
            unless casecmp?(hHost, host) \
                || casecmp?(sName, host) \
                || (!host && (casecmp?(hHost, sName) ||
                              casecmp?(hHost, sName+':'+sPort)))
              next
            end

            next unless m = match.match(path.to_s)

            rest = m[1]
            next unless !rest || rest.empty? || rest[0] == ?/

            env['SCRIPT_NAME'] = (script_name + location)
            env['PATH_INFO'] = rest

            return app.call(env)
          end

          [404, {CONTENT_TYPE => "text/plain", "X-Cascade" => "pass"}, ["Not Found: #{path}"]]

        ensure
          env['PATH_INFO'] = path
          env['SCRIPT_NAME'] = script_name
        end