Archive of RubyForge sup-talk mailing list
 help / color / mirror / Atom feed
* [sup-talk] [PATCH] decoding: handle more misspellings, in particular ISO-8859-15
@ 2009-03-16 18:56 Nicolas Pouillard
  2009-03-23 14:57 ` William Morgan
  0 siblings, 1 reply; 2+ messages in thread
From: Nicolas Pouillard @ 2009-03-16 18:56 UTC (permalink / raw)


Resent...

---
 lib/sup/util.rb |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/lib/sup/util.rb b/lib/sup/util.rb
index fc62532..dbcffcc 100644
--- a/lib/sup/util.rb
+++ b/lib/sup/util.rb
@@ -620,11 +620,12 @@ end
 
 class Iconv
   def self.easy_decode target, charset, text
-    return text if charset =~ /^(x-unknown|unknown[-_]?8bit|ascii[-_]?7[-_]?bit)$/i
+    return text if charset =~ /^(x-unknown|unknown[-_ ]?8bit|ascii[-_ ]?7[-_ ]?bit)$/i
     charset = case charset
-                when /UTF[-_]?8/i: "utf-8"
-                when /(iso[-_])?latin[-_]?1$/i: "ISO-8859-1"
-                when /unicode[-_]1[-_]1[-_]utf[-_]7/i: "utf-7"
+                when /UTF[-_ ]?8/i: "utf-8"
+                when /(iso[-_ ])?latin[-_ ]?1$/i: "ISO-8859-1"
+                when /iso[-_ ]?8859[-_ ]?15/i: 'ISO-8859-15'
+                when /unicode[-_ ]1[-_ ]1[-_ ]utf[-_]7/i: "utf-7"
                 else charset
               end
 

-- 
Nicolas Pouillard


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [sup-talk] [PATCH] decoding: handle more misspellings, in particular ISO-8859-15
  2009-03-16 18:56 [sup-talk] [PATCH] decoding: handle more misspellings, in particular ISO-8859-15 Nicolas Pouillard
@ 2009-03-23 14:57 ` William Morgan
  0 siblings, 0 replies; 2+ messages in thread
From: William Morgan @ 2009-03-23 14:57 UTC (permalink / raw)


Thanks! Branch encoding-misspellings, merged into next.
-- 
William <wmorgan-sup at masanjin.net>


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-03-23 14:57 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-03-16 18:56 [sup-talk] [PATCH] decoding: handle more misspellings, in particular ISO-8859-15 Nicolas Pouillard
2009-03-23 14:57 ` William Morgan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox