[前][次][番号順一覧][スレッド一覧]

ruby-changes:39437

From: nagachika <ko1@a...>
Date: Tue, 11 Aug 2015 00:34:29 +0900 (JST)
Subject: [ruby-changes:39437] nagachika:r51518 (ruby_2_2): merge revision(s) 50089: [Backport #11342]

nagachika	2015-08-11 00:33:59 +0900 (Tue, 11 Aug 2015)

  New Revision: 51518

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=51518

  Log:
    merge revision(s) 50089: [Backport #11342]
    
    * ext/socket/extconf.rb: Solaris 11 has struct tcp_info.tcpi_ca_state,
      but it is a dummy.
    
    * ext/socket/option.c: Solaris 11 doesn't have u_intN_t.
    
    * ext/socket/option.c: Solaris 11 needs inspect_tcpi_msec.
    
    * ext/socket/raddrinfo.c: Solaris 11 has AF_PACKET but doesn't have
      related macros.

  Modified directories:
    branches/ruby_2_2/
  Modified files:
    branches/ruby_2_2/ChangeLog
    branches/ruby_2_2/ext/socket/extconf.rb
    branches/ruby_2_2/ext/socket/option.c
    branches/ruby_2_2/ext/socket/raddrinfo.c
    branches/ruby_2_2/version.h
Index: ruby_2_2/ChangeLog
===================================================================
--- ruby_2_2/ChangeLog	(revision 51517)
+++ ruby_2_2/ChangeLog	(revision 51518)
@@ -1,3 +1,15 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_2/ChangeLog#L1
+Tue Aug 11 00:21:56 2015  NARUSE, Yui  <naruse@r...>
+
+	* ext/socket/extconf.rb: Solaris 11 has struct tcp_info.tcpi_ca_state,
+	  but it is a dummy.
+
+	* ext/socket/option.c: Solaris 11 doesn't have u_intN_t.
+
+	* ext/socket/option.c: Solaris 11 needs inspect_tcpi_msec.
+
+	* ext/socket/raddrinfo.c: Solaris 11 has AF_PACKET but doesn't have
+	  related macros.
+
 Tue Aug  4 04:11:34 2015  Tanaka Akira  <akr@f...>
 
 	* lib/time.rb (strptime): Support %s.%N.
Index: ruby_2_2/ext/socket/option.c
===================================================================
--- ruby_2_2/ext/socket/option.c	(revision 51517)
+++ ruby_2_2/ext/socket/option.c	(revision 51518)
@@ -883,14 +883,14 @@ inspect_ipv6_mreq(int level, int optname https://github.com/ruby/ruby/blob/trunk/ruby_2_2/ext/socket/option.c#L883
 #endif
 
 static void
-inspect_tcpi_options(VALUE ret, u_int8_t options)
+inspect_tcpi_options(VALUE ret, uint8_t options)
 {
     int sep = '=';
 
     rb_str_cat2(ret, " options");
 #define INSPECT_TCPI_OPTION(optval, name) \
     if (options & (optval)) { \
-        options &= ~(u_int8_t)(optval); \
+        options &= ~(uint8_t)(optval); \
         rb_str_catf(ret, "%c%s", sep, name); \
         sep = ','; \
     }
@@ -923,14 +923,14 @@ inspect_tcpi_options(VALUE ret, u_int8_t https://github.com/ruby/ruby/blob/trunk/ruby_2_2/ext/socket/option.c#L923
 }
 
 static void
-inspect_tcpi_usec(VALUE ret, const char *prefix, u_int32_t t)
+inspect_tcpi_usec(VALUE ret, const char *prefix, uint32_t t)
 {
     rb_str_catf(ret, "%s%u.%06us", prefix, t / 1000000, t % 1000000);
 }
 
-#ifdef __linux__
+#if defined(__linux__) || defined(__sun)
 static void
-inspect_tcpi_msec(VALUE ret, const char *prefix, u_int32_t t)
+inspect_tcpi_msec(VALUE ret, const char *prefix, uint32_t t)
 {
     rb_str_catf(ret, "%s%u.%03us", prefix, t / 1000, t % 1000);
 }
Index: ruby_2_2/ext/socket/raddrinfo.c
===================================================================
--- ruby_2_2/ext/socket/raddrinfo.c	(revision 51517)
+++ ruby_2_2/ext/socket/raddrinfo.c	(revision 51518)
@@ -1210,7 +1210,7 @@ rsock_inspect_sockaddr(struct sockaddr * https://github.com/ruby/ruby/blob/trunk/ruby_2_2/ext/socket/raddrinfo.c#L1210
           }
 #endif
 
-#ifdef AF_PACKET
+#if defined(AF_PACKET) && defined(__linux__)
           /* GNU/Linux */
           case AF_PACKET:
           {
Index: ruby_2_2/ext/socket/extconf.rb
===================================================================
--- ruby_2_2/ext/socket/extconf.rb	(revision 51517)
+++ ruby_2_2/ext/socket/extconf.rb	(revision 51518)
@@ -384,7 +384,9 @@ if have_type("struct tcp_info", headers) https://github.com/ruby/ruby/blob/trunk/ruby_2_2/ext/socket/extconf.rb#L384
   have_const("TCP_LISTEN", headers)
   have_const("TCP_CLOSING", headers)
   have_struct_member('struct tcp_info', 'tcpi_state', headers)
-  have_struct_member('struct tcp_info', 'tcpi_ca_state', headers)
+  if /solaris/ !~ RUBY_PLATFORM
+    have_struct_member('struct tcp_info', 'tcpi_ca_state', headers)
+  end
   have_struct_member('struct tcp_info', 'tcpi_retransmits', headers)
   have_struct_member('struct tcp_info', 'tcpi_probes', headers)
   have_struct_member('struct tcp_info', 'tcpi_backoff', headers)
Index: ruby_2_2/version.h
===================================================================
--- ruby_2_2/version.h	(revision 51517)
+++ ruby_2_2/version.h	(revision 51518)
@@ -1,10 +1,10 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_2/version.h#L1
 #define RUBY_VERSION "2.2.3"
-#define RUBY_RELEASE_DATE "2015-08-04"
-#define RUBY_PATCHLEVEL 150
+#define RUBY_RELEASE_DATE "2015-08-11"
+#define RUBY_PATCHLEVEL 151
 
 #define RUBY_RELEASE_YEAR 2015
 #define RUBY_RELEASE_MONTH 8
-#define RUBY_RELEASE_DAY 4
+#define RUBY_RELEASE_DAY 11
 
 #include "ruby/version.h"
 

Property changes on: ruby_2_2
___________________________________________________________________
Modified: svn:mergeinfo
   Merged /trunk:r50089


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]