rack-devel archive mirror (unofficial) https://groups.google.com/group/rack-devel
 help / color / mirror / Atom feed
From: "Matthew M. Boedicker" <matthewm@boedicker.org>
To: rack-devel@googlegroups.com
Subject: rack 1.2.1 and ruby < 1.8.7
Date: Tue, 10 Aug 2010 19:40:05 -0400	[thread overview]
Message-ID: <AANLkTim0xZakTzBA-b8Sn4nJUZ4Mkxry+BsGoxchCn6P@mail.gmail.com> (raw)


[-- Attachment #1.1: Type: text/plain, Size: 252 bytes --]

The rack 1.2.1 gem breaks on ruby < 1.8.7 because Regexp.union does not take
an array argument. This patch fixes it. If you are opposed to changing
things to support very old versions of ruby maybe at least the gem could
require ruby 1.8.7 or greater.

[-- Attachment #1.2: Type: text/html, Size: 266 bytes --]

[-- Attachment #2: rack_utils_ruby_1_8_5_patch.txt --]
[-- Type: text/plain, Size: 399 bytes --]

--- utils.rb.orig	2010-08-10 16:30:52.203112000 -0700
+++ utils.rb	2010-08-10 16:31:08.276685000 -0700
@@ -135,7 +135,7 @@
       "'" => "&#39;",
       '"' => "&quot;",
     }
-    ESCAPE_HTML_PATTERN = Regexp.union(ESCAPE_HTML.keys)
+    ESCAPE_HTML_PATTERN = Regexp.union(*ESCAPE_HTML.keys)
 
     # Escape ampersands, brackets and quotes to their HTML/XML entities.
     def escape_html(string)

             reply	other threads:[~2010-08-10 23:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-10 23:40 Matthew M. Boedicker [this message]
2010-08-10 23:47 ` rack 1.2.1 and ruby < 1.8.7 Matthew M. Boedicker

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://groups.google.com/group/rack-devel

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=AANLkTim0xZakTzBA-b8Sn4nJUZ4Mkxry+BsGoxchCn6P@mail.gmail.com \
    --to=rack-devel@googlegroups.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).