Commit 404ece4e authored by rswindell's avatar rswindell
Browse files

nopen() didn't set the correct share value if O_TEXT and O_RDONLY open mode

was specified.
parent 91f543d3
......@@ -49,9 +49,12 @@ int nopen(const char* str, int access)
if(access&O_DENYNONE) {
share=SH_DENYNO;
access&=~O_DENYNONE; }
else if((access&~O_BINARY)==O_RDONLY) share=SH_DENYWR;
else share=SH_DENYRW;
access&=~O_DENYNONE;
}
else if((access&~(O_TEXT|O_BINARY))==O_RDONLY)
share=SH_DENYWR;
else
share=SH_DENYRW;
#if !defined(__unix__) /* Basically, a no-op on Unix anyway */
if(!(access&O_TEXT))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment