[DRE-commits] [ruby-patron] 03/04: Drop upstream applied patches
zeha at debian.org
zeha at debian.org
Thu Dec 17 00:06:10 UTC 2015
This is an automated email from the git hooks/post-receive script.
zeha pushed a commit to annotated tag debian/0.5.0-1
in repository ruby-patron.
commit 54eabf32f553a75b42d60e1cb61b04bbb52f63da
Author: Christian Hofstaedtler <zeha at debian.org>
Date: Wed Dec 16 22:57:51 2015 +0000
Drop upstream applied patches
---
debian/patches/disabled_sslv3.patch | 10 +++---
debian/patches/fix_incorrect_element.patch | 41 ---------------------
debian/patches/ruby22.patch | 57 ------------------------------
debian/patches/series | 2 --
debian/patches/tests-disable-load-path | 10 +++---
5 files changed, 11 insertions(+), 109 deletions(-)
diff --git a/debian/patches/disabled_sslv3.patch b/debian/patches/disabled_sslv3.patch
index 35d9a64..b1a102d 100644
--- a/debian/patches/disabled_sslv3.patch
+++ b/debian/patches/disabled_sslv3.patch
@@ -2,9 +2,11 @@ Author: Jonas Genannt <genannt at debian.org>
Description: SSLv3 is obsolete, remove test
Forwarded: not-needed
---- a/spec/session_ssl_spec.rb
-+++ b/spec/session_ssl_spec.rb
-@@ -261,7 +261,7 @@
+Index: ruby-patron/spec/session_ssl_spec.rb
+===================================================================
+--- ruby-patron.orig/spec/session_ssl_spec.rb
++++ ruby-patron/spec/session_ssl_spec.rb
+@@ -260,7 +260,7 @@ describe Patron::Session do
end
it "should work with different SSL versions" do
@@ -12,4 +14,4 @@ Forwarded: not-needed
+ ['TLSv1'].each do |version|
@session.ssl_version = version
response = @session.get("/test")
- response.status.should == 200
+ expect(response.status).to be == 200
diff --git a/debian/patches/fix_incorrect_element.patch b/debian/patches/fix_incorrect_element.patch
deleted file mode 100644
index 8e6c90e..0000000
--- a/debian/patches/fix_incorrect_element.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From 62135866a7533941c927d06cf47a2813f2f68256 Mon Sep 17 00:00:00 2001
-From: Vladimir Kochnev <hashtable at yandex.ru>
-Date: Mon, 18 May 2015 17:33:24 +0300
-Subject: [PATCH] Fix incorrect list element comparator.
-Bug: https://github.com/marshall-lee/patron/commit/62135866a7533941c927d06cf47a2813f2f68256
-
-List elements was being comparing incorrectly.
-C operator `==` returns 1 on equal elements but SGLIB wants a zero.
-As a consequence `ruby_xfree` was being calling on memory regions that are in
-use. It caused random segfaults when using Patron.
-
-Also this patch optimizes list element deletion: there is a convenient
-SGLIB macro `SGLIB_LIST_DELETE_IF_MEMBER` so there's no need to go
-through list twice.
----
- ext/patron/session_ext.c | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
---- a/ext/patron/session_ext.c
-+++ b/ext/patron/session_ext.c
-@@ -109,7 +109,7 @@
- struct curl_state_list *next;
- };
-
--#define CS_LIST_COMPARATOR(p, _state_) (p->state == _state_)
-+#define CS_LIST_COMPARATOR(p, _state_) (p->state - _state_)
-
- static struct curl_state_list *cs_list = NULL;
-
-@@ -128,9 +128,9 @@
- struct curl_state_list *item = NULL;
-
- assert(state != NULL);
-- SGLIB_LIST_FIND_MEMBER(struct curl_state_list, cs_list, state, CS_LIST_COMPARATOR, next, item);
-+
-+ SGLIB_LIST_DELETE_IF_MEMBER(struct curl_state_list, cs_list, state, CS_LIST_COMPARATOR, next, item);
- if (item) {
-- SGLIB_LIST_DELETE(struct curl_state_list, cs_list, item, next);
- ruby_xfree(item);
- }
- }
diff --git a/debian/patches/ruby22.patch b/debian/patches/ruby22.patch
deleted file mode 100644
index 0b9d0be..0000000
--- a/debian/patches/ruby22.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-From cb5b3f7b2529a30a987845611da5e84e1897172d Mon Sep 17 00:00:00 2001
-From: Vladimir Kochnev <hashtable at yandex.ru>
-Date: Fri, 15 May 2015 14:40:16 +0300
-Subject: [PATCH] use rb_thread_call_without_gvl if possible
-
-rb_thread_blocking_region is deprecated since 2.0 and completely removed
-in 2.2. rb_thread_call_without_gvl should be used instead on all rubies
-that already have it.
----
- ext/patron/extconf.rb | 4 +++-
- ext/patron/session_ext.c | 12 +++++++++++-
- 2 files changed, 14 insertions(+), 2 deletions(-)
-
---- a/ext/patron/extconf.rb
-+++ b/ext/patron/extconf.rb
-@@ -44,6 +44,8 @@
- end
-
- $defs.push("-DUSE_TBR")
--$defs.push("-DHAVE_TBR") if have_func('rb_thread_blocking_region')
-+$defs.push("-DHAVE_THREAD_H") if have_header('ruby/thread.h')
-+$defs.push("-DHAVE_TBR") if have_func('rb_thread_blocking_region', 'ruby.h')
-+$defs.push("-DHAVE_TCWOGVL") if have_header('ruby/thread.h') && have_func('rb_thread_call_without_gvl', 'ruby/thread.h')
-
- create_makefile 'patron/session_ext'
---- a/ext/patron/session_ext.c
-+++ b/ext/patron/session_ext.c
-@@ -23,6 +23,9 @@
- *
- \* -------------------------------------------------------------------------- */
- #include <ruby.h>
-+#if defined(USE_TBR) && defined(HAVE_THREAD_H)
-+#include <ruby/thread.h>
-+#endif
- #include <curl/curl.h>
- #include "membuffer.h"
- #include "sglib.h" /* Simple Generic Library -> http://sglib.sourceforge.net */
-@@ -593,11 +596,18 @@
- curl_easy_setopt(curl, CURLOPT_WRITEDATA, body_buffer);
- }
-
--#if defined(HAVE_TBR) && defined(USE_TBR)
-+#if (defined(HAVE_TBR) || defined(HAVE_TCWOGVL)) && defined(USE_TBR)
-+#if defined(HAVE_TCWOGVL)
-+ ret = (CURLcode) rb_thread_call_without_gvl(
-+ (void *(*)(void *)) curl_easy_perform, curl,
-+ RUBY_UBF_IO, 0
-+ );
-+#else
- ret = (CURLcode) rb_thread_blocking_region(
- (rb_blocking_function_t*) curl_easy_perform, curl,
- RUBY_UBF_IO, 0
- );
-+#endif
- #else
- ret = curl_easy_perform(curl);
- #endif
diff --git a/debian/patches/series b/debian/patches/series
index c58f52f..2e86848 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,4 +1,2 @@
tests-disable-load-path
disabled_sslv3.patch
-fix_incorrect_element.patch
-ruby22.patch
diff --git a/debian/patches/tests-disable-load-path b/debian/patches/tests-disable-load-path
index 7974d46..74f1bba 100644
--- a/debian/patches/tests-disable-load-path
+++ b/debian/patches/tests-disable-load-path
@@ -7,11 +7,11 @@ Description: Test suite: Remove load path modifications
Index: ruby-patron/spec/spec_helper.rb
===================================================================
---- ruby-patron.orig/spec/spec_helper.rb 2014-03-05 20:44:17.814566313 +0100
-+++ ruby-patron/spec/spec_helper.rb 2014-03-05 20:47:25.190033067 +0100
-@@ -23,8 +23,6 @@
- ## -------------------------------------------------------------------
- require 'rspec'
+--- ruby-patron.orig/spec/spec_helper.rb
++++ ruby-patron/spec/spec_helper.rb
+@@ -33,8 +33,6 @@ require 'rspec'
+ # to fail with another exception
+ RSpec::Expectations.configuration.warn_about_potential_false_positives = false
-$:.unshift(File.dirname(__FILE__) + '/../lib')
-$:.unshift(File.dirname(__FILE__) + '/../ext')
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ruby-extras/ruby-patron.git
More information about the Pkg-ruby-extras-commits
mailing list