|[ < ]||[ > ]||[ << ]||[ Up ]||[ >> ]||[Top]||[Contents]||[Index]||[ ? ]|
#include <fcntl.h> int __djgpp_share_flags = ...;
This variable controls the share flags used by
open (and hence
fopen) when opening a file.
If you assign any value other than 0 to this variable libc will use
that value for the sharing bits when if calls DOS to open the file.
But if you specify any share flag in the
open call then these
flags will remain untouched. In this way
acts just like a default and by default is 0 ensuring maximum
compatibility with older versions of djgpp.
If you don't know how the share flags act consult any DOS reference. They
allow to share or protect a file when it's opened more than once by the
same task or by two or more tasks. The exact behavior depends on the exact
case. One interesting thing is that when the file is opened by two tasks
under Windows the results are different if you use Windows 3.1 or Windows 95.
To add even more complexity Windows 3.1 is affected by
The available flags are:
That's the compatible mode.
Deny read and deny write.
Of course these flags are DOS specific and doesn't exist under other OSs;
and as you can imagine
__djgpp_share_flags is djgpp specific.
See section open. See section fopen.
|webmaster||delorie software privacy|
|Copyright © 2004||Updated Apr 2004|