From: normalperson@yhbt.net
To: kgio@librelist.org
Subject: [PATCH 1/2] only define and test kgio_syssend on 1.9+
Date: Wed, 5 Feb 2014 07:56:46 +0000 [thread overview]
Message-ID: <1391587007-30124-2-git-send-email-normalperson@yhbt.net> (raw)
In-Reply-To: 1391587007-30124-1-git-send-email-normalperson@yhbt.net
From: Eric Wong <e@80x24.org>
Reported-by: Christopher Rigor <crigor@gmail.com>
---
ext/kgio/write.c | 2 +-
test/test_syssend.rb | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/ext/kgio/write.c b/ext/kgio/write.c
index 04f2866..ad34bdd 100644
--- a/ext/kgio/write.c
+++ b/ext/kgio/write.c
@@ -261,7 +261,7 @@ void init_kgio_write(void)
rb_define_method(mSocketMethods, "kgio_write", kgio_send, 1);
rb_define_method(mSocketMethods, "kgio_trywrite", kgio_trysend, 1);
-#ifdef USE_MSG_DONTWAIT
+#if defined(KGIO_HAVE_THREAD_CALL_WITHOUT_GVL)
rb_define_method(mSocketMethods, "kgio_syssend", kgio_syssend, 2);
#endif
}
diff --git a/test/test_syssend.rb b/test/test_syssend.rb
index 5089ce3..7d2511a 100644
--- a/test/test_syssend.rb
+++ b/test/test_syssend.rb
@@ -40,4 +40,4 @@ class TestKgioSyssend < Test::Unit::TestCase
ensure
[ srv, acc, client ].each { |io| io.close if io }
end
-end if RUBY_PLATFORM =~ /linux/
+end if RUBY_PLATFORM =~ /linux/ && Socket.const_defined?(:MSG_MORE)
--
1.8.5.3.368.gab0bcec
next prev parent reply other threads:[~2014-02-05 7:57 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-05 7:56 [PATCH 0/2] Ruby 1.8 fixes normalperson
2014-02-05 7:56 ` normalperson [this message]
2014-02-05 7:56 ` [PATCH 2/2] various 1.8.7 fixes normalperson
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-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://yhbt.net/kgio/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1391587007-30124-2-git-send-email-normalperson@yhbt.net \
--to=normalperson@yhbt.net \
--cc=kgio@librelist.org \
/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.
Code repositories for project(s) associated with this public inbox
https://yhbt.net/kgio.git/
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).