[DRE-commits] [SCM] sup-mail.git branch, master, updated. debian/0.12.1+git20120407.aaa852f-1-1-g5fac7bc

Per Andersson avtobiff at gmail.com
Thu Aug 2 22:59:37 UTC 2012


The following commit has been merged in the master branch:
commit 5fac7bc67093d6770a6f5926276cb05769723232
Author: Per Andersson <avtobiff at gmail.com>
Date:   Fri Aug 3 00:58:51 2012 +0200

    Updated text wrapping patch (0004) to work with Ruby 1.9

diff --git a/debian/changelog b/debian/changelog
index 0441e8a..9d38aac 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+sup-mail (0.12.1+git20120407.aaa852f-2) UNRELEASED; urgency=low
+
+  * Updated text wrapping patch (0004) to work with Ruby 1.9.
+
+ -- Per Andersson <avtobiff at gmail.com>  Fri, 03 Aug 2012 00:57:55 +0200
+
 sup-mail (0.12.1+git20120407.aaa852f-1) unstable; urgency=low
 
   * New maintainer. (Closes: #660509)
diff --git a/debian/patches/0004-Avoid-crash-when-maybe-wrapping-text.patch b/debian/patches/0004-Avoid-crash-when-maybe-wrapping-text.patch
index 06b7a37..fb6de06 100644
--- a/debian/patches/0004-Avoid-crash-when-maybe-wrapping-text.patch
+++ b/debian/patches/0004-Avoid-crash-when-maybe-wrapping-text.patch
@@ -4,18 +4,23 @@ Subject: Avoid crash when (maybe) wrapping text.
 
 Crash occurs for instance when expanding GPG signatures.
 ---
- lib/sup/modes/thread-view-mode.rb |    3 ++-
- 1 files changed, 2 insertions(+), 1 deletions(-)
+ lib/sup/modes/thread-view-mode.rb |    8 +++++++-
+ 1 files changed, 7 insertions(+), 1 deletions(-)
 
 diff --git a/lib/sup/modes/thread-view-mode.rb b/lib/sup/modes/thread-view-mode.rb
-index 9fcc45d..2a8a237 100644
+index 9fcc45d..510f967 100644
 --- a/lib/sup/modes/thread-view-mode.rb
 +++ b/lib/sup/modes/thread-view-mode.rb
-@@ -846,7 +846,8 @@ private
+@@ -846,7 +846,13 @@ private
        else
          width = buffer.content_width
        end
 -      lines = lines.map { |l| l.chomp.wrap width }.flatten
++      # this function apparently takes both String and Array as input.
++      # if String convert to Array so map works.
++      if lines.kind_of? String
++        lines = lines.lines.to_a
++      end
 +      # sometimes l is nil, avoid crash when this happens
 +      lines = lines.map { |l| l.chomp.wrap width unless l == nil }.flatten
      end

-- 
sup-mail.git



More information about the Pkg-ruby-extras-commits mailing list