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

ruby-changes:10830

From: nobu <ko1@a...>
Date: Wed, 18 Feb 2009 15:36:02 +0900 (JST)
Subject: [ruby-changes:10830] Ruby:r22399 (trunk): * file.c (rb_file_chown): use chown unless HAVE_FCHOWN.

nobu	2009-02-18 15:35:38 +0900 (Wed, 18 Feb 2009)

  New Revision: 22399

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

  Log:
    * file.c (rb_file_chown): use chown unless HAVE_FCHOWN.

  Modified files:
    trunk/ChangeLog
    trunk/file.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 22398)
+++ ChangeLog	(revision 22399)
@@ -1,5 +1,7 @@
-Wed Feb 18 15:33:51 2009  Nobuyoshi Nakada  <nobu@r...>
+Wed Feb 18 15:35:36 2009  Nobuyoshi Nakada  <nobu@r...>
 
+	* file.c (rb_file_chown): use chown unless HAVE_FCHOWN.
+
 	* io.c (pipe_open): sarg is always used unless HAVE_FORK.
 
 Wed Feb 18 15:23:34 2009  Akinori MUSHA  <knu@i...>
Index: file.c
===================================================================
--- file.c	(revision 22398)
+++ file.c	(revision 22399)
@@ -1998,7 +1998,7 @@
     o = NIL_P(owner) ? -1 : NUM2INT(owner);
     g = NIL_P(group) ? -1 : NUM2INT(group);
     GetOpenFile(obj, fptr);
-#if defined(__CYGWIN32__) || defined(_WIN32) || defined(__EMX__) || defined(__SYMBIAN32__)
+#ifndef HAVE_FCHOWN
     if (NIL_P(fptr->pathv)) return Qnil;
     if (chown(RSTRING_PTR(fptr->pathv), o, g) == -1)
 	rb_sys_fail_path(fptr->pathv);

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

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