I don't think that'll work. fchmod() isn't equivalent to _chmod().
The prior takes a file descriptor (int), the latter takes a file path (char *).
I'll revisit that logic in libbu to see what needs to change (probably just calling chmod() and living with the race condition on Windows.
Cheers!
Sean
On Jan 17, 2012, at 11:20 AM, [email protected] wrote:
Revision: 48885
http://brlcad.svn.sourceforge.net/brlcad/?rev=48885&view=rev
Author: d_rossberg
Date: 2012-01-17 16:20:17 +0000 (Tue, 17 Jan 2012)
Log Message:
-----------
two additional Windows symbol equivalences (fchmod(), mode_t)
Modified Paths:
--------------
brlcad/trunk/include/config_win.h
brlcad/trunk/include/config_win_cmake.h.in
Modified: brlcad/trunk/include/config_win.h
===================================================================
--- brlcad/trunk/include/config_win.h 2012-01-17 15:54:14 UTC (rev 48884)
+++ brlcad/trunk/include/config_win.h 2012-01-17 16:20:17 UTC (rev 48885)
@@ -120,6 +120,7 @@
#define creat _creat
#define dup _dup
#define dup2 _dup2
+#define fchmod _chmod
/* #define filelength _filelength */
#define isatty _isatty
#define locking _locking
@@ -181,6 +182,7 @@
typedef int socklen_t;
typedef unsigned int gid_t;
typedef unsigned int uid_t;
+typedef int mode_t;
/*
Modified: brlcad/trunk/include/config_win_cmake.h.in
===================================================================
--- brlcad/trunk/include/config_win_cmake.h.in 2012-01-17 15:54:14 UTC (rev 48884)
+++ brlcad/trunk/include/config_win_cmake.h.in 2012-01-17 16:20:17 UTC (rev 48885)
@@ -106,6 +106,7 @@
#define creat _creat
#define dup _dup
#define dup2 _dup2
+#define fchmod _chmod
/* #define filelength _filelength */
#define isatty _isatty
#define locking _locking
@@ -167,6 +168,7 @@
typedef int socklen_t;
typedef unsigned int gid_t;
typedef unsigned int uid_t;
+typedef int mode_t;
/*
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://listssourceforge.net/lists/listinfo/brlcad-commits
------------------------------------------------------------------------------ Keep Your Developer Skills Current with LearnDevNow! The most comprehensive online learning library for Microsoft developers is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, Metro Style Apps, more. Free future releases when you subscribe now! http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________ BRL-CAD Developer mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/brlcad-devel
