Re: r15913 - in /lyx-devel/trunk: development/cmake/config.h....

2006-11-17 Thread Andre Poenitz
On Tue, Nov 14, 2006 at 11:45:50AM +0100, Peter Kümmel wrote: > bool lyx::support::chmod(string const & file, unsigned long int mode) > { > #ifdef HAVE_CHMOD > +#ifdef _MSC_VER > + if (mode == 400 || mode == 040 || mode ==004) > + mode = _S_IREAD; > + else if (mode == 2

Re: r15913 - in /lyx-devel/trunk: development/cmake/config.h....

2006-11-14 Thread Peter Kümmel
Georg Baum wrote: > Peter Kümmel wrote: > >> Is this mapping OK? > > Sorry, only after reading the mapping I realize that my suggestion does not > make sense: We want to make the file unreadable for other users. This is > not possible with the windows variant of chmod, so I think it is best to >

Re: r15913 - in /lyx-devel/trunk: development/cmake/config.h....

2006-11-14 Thread Georg Baum
Peter Kümmel wrote: > Is this mapping OK? Sorry, only after reading the mapping I realize that my suggestion does not make sense: We want to make the file unreadable for other users. This is not possible with the windows variant of chmod, so I think it is best to not use chmod on windows at all.

Re: r15913 - in /lyx-devel/trunk: development/cmake/config.h....

2006-11-14 Thread Georg Baum
Peter Kümmel wrote: > msvc only supports S_IWRITE/READ, seems it is better to disable it. > Are there reasons not to disable it on Windows? Since we basically want to make files and directories readonly you could also map the mode arguments to S_IWRITE/READ. The same holds for directory creation.

Re: r15913 - in /lyx-devel/trunk: development/cmake/config.h....

2006-11-14 Thread Peter Kümmel
Georg Baum wrote: > Peter Kümmel wrote: > >> msvc only supports S_IWRITE/READ, seems it is better to disable it. >> Are there reasons not to disable it on Windows? > > Since we basically want to make files and directories readonly you could > also map the mode arguments to S_IWRITE/READ. The same

Re: r15913 - in /lyx-devel/trunk: development/cmake/config.h....

2006-11-14 Thread Peter Kümmel
Georg Baum wrote: > [EMAIL PROTECTED] wrote: > >> Modified: lyx-devel/trunk/development/cmake/config.h.cmake >> URL: >> > http://www.lyx.org/trac/file/lyx-devel/trunk/development/cmake/config.h.cmake?rev=15913 > == >> ---

Re: r15913 - in /lyx-devel/trunk: development/cmake/config.h....

2006-11-14 Thread Georg Baum
[EMAIL PROTECTED] wrote: > Modified: lyx-devel/trunk/development/cmake/config.h.cmake > URL: > http://www.lyx.org/trac/file/lyx-devel/trunk/development/cmake/config.h.cmake?rev=15913 > == > --- lyx-devel/trunk/development/