Commit b69efabc authored by rswindell's avatar rswindell
Browse files

nopen needed S_IREAD|S_WRITE in sopen() call (whoops).

parent ca60b3c0
......@@ -2513,7 +2513,7 @@ int sbbs_t::nopen(char *str, int access)
else share=SH_DENYRW;
if(!(access&O_TEXT))
access|=O_BINARY;
while(((file=sopen(str,access,share))==-1)
while(((file=sopen(str,access,share,S_IREAD|S_IWRITE))==-1)
&& (errno==EACCES || errno==EAGAIN) && count++<LOOP_NOPEN)
mswait(100);
if(count>(LOOP_NOPEN/2) && count<=LOOP_NOPEN) {
......
......@@ -8,7 +8,7 @@
* @format.tab-size 4 (Plain Text/Source Code File Header) *
* @format.use-tabs true (see http://www.synchro.net/ptsc_hdr.html) *
* *
* Copyright 2000 Rob Swindell - http://www.synchro.net/copyright.html *
* Copyright 2003 Rob Swindell - http://www.synchro.net/copyright.html *
* *
* This program is free software; you can redistribute it and/or *
* modify it under the terms of the GNU General Public License *
......@@ -54,7 +54,7 @@ int nopen(char *str, int access)
else share=SH_DENYRW;
if(!(access&O_TEXT))
access|=O_BINARY;
while(((file=sopen(str,access,share))==-1)
while(((file=sopen(str,access,share,S_IREAD|S_IWRITE))==-1)
&& (errno==EACCES || errno==EAGAIN) && count++<LOOP_NOPEN)
if(count)
mswait(100);
......
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