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

ruby-changes:17887

From: usa <ko1@a...>
Date: Wed, 24 Nov 2010 15:44:58 +0900 (JST)
Subject: [ruby-changes:17887] Ruby:r29901 (ruby_1_8): * ext/socket/extconf.rb (getaddrinfo): should initialize winsock on

usa	2010-11-24 15:44:52 +0900 (Wed, 24 Nov 2010)

  New Revision: 29901

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

  Log:
    * ext/socket/extconf.rb (getaddrinfo): should initialize winsock on
      windows.

  Modified files:
    branches/ruby_1_8/ChangeLog
    branches/ruby_1_8/ext/socket/extconf.rb

Index: ruby_1_8/ext/socket/extconf.rb
===================================================================
--- ruby_1_8/ext/socket/extconf.rb	(revision 29900)
+++ ruby_1_8/ext/socket/extconf.rb	(revision 29901)
@@ -142,7 +142,12 @@
   int passive, gaierr, inet4 = 0, inet6 = 0;
   struct addrinfo hints, *ai, *aitop;
   char straddr[INET6_ADDRSTRLEN], strport[16];
+#ifdef _WIN32
+  WSADATA retdata;
 
+  WSAStartup(MAKEWORD(2, 0), &retdata);
+#endif
+
   for (passive = 0; passive <= 1; passive++) {
     memset(&hints, 0, sizeof(hints));
     hints.ai_family = AF_UNSPEC;
Index: ruby_1_8/ChangeLog
===================================================================
--- ruby_1_8/ChangeLog	(revision 29900)
+++ ruby_1_8/ChangeLog	(revision 29901)
@@ -1,3 +1,8 @@
+Wed Nov 24 15:44:11 2010  NAKAMURA Usaku  <usa@r...>
+
+	* ext/socket/extconf.rb (getaddrinfo): should initialize winsock on
+	  windows.
+
 Wed Nov 24 13:55:21 2010  NAKAMURA Usaku  <usa@r...>
 
 	* win32/setup.mak: use findstr.exe instead of find.exe, because all

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

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