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

ruby-changes:33687

From: ngoto <ko1@a...>
Date: Thu, 1 May 2014 00:38:36 +0900 (JST)
Subject: [ruby-changes:33687] ngoto:r45768 (trunk): * file.c (FSTATFS): check availability of struct statfs and

ngoto	2014-05-01 00:38:31 +0900 (Thu, 01 May 2014)

  New Revision: 45768

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

  Log:
    * file.c (FSTATFS): check availability of struct statfs and
      struct statvfs in addition to fstatfs(2) and fstatvfs(2).
      This fixes error in Solaris. [Bug #9788] [ruby-dev:48145]

  Modified files:
    trunk/ChangeLog
    trunk/file.c
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 45767)
+++ ChangeLog	(revision 45768)
@@ -1,3 +1,9 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Thu May  1 00:36:26 2014  Naohisa Goto  <ngotogenome@g...>
+
+	* file.c (FSTATFS): check availability of struct statfs and
+	  struct statvfs in addition to fstatfs(2) and fstatvfs(2).
+	  This fixes error in Solaris. [Bug #9788] [ruby-dev:48145]
+
 Wed Apr 30 19:46:23 2014  Narihiro Nakamura  <authornari@g...>
 
 	* gc.c (gc_after_sweep): suppress unnecessary expanding heap.
Index: file.c
===================================================================
--- file.c	(revision 45767)
+++ file.c	(revision 45768)
@@ -92,9 +92,9 @@ typedef struct statvfs statfs_t; https://github.com/ruby/ruby/blob/trunk/file.c#L92
 #endif
 #ifndef WITHOUT_STATFS
 static VALUE rb_statfs_new(const statfs_t *st);
-#if defined(HAVE_FSTATFS)
+#if defined(HAVE_FSTATFS) && defined(HAVE_STRUCT_STATFS)
 #define FSTATFS(f, s) fstatfs((f), (s))
-#elif defined(HAVE_FSTATVFS)
+#elif defined(HAVE_FSTATVFS) && defined(HAVE_STRUCT_STATVFS)
 #define FSTATFS(f, s) fstatvfs((f), (s))
 #endif
 #endif

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

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