diff --git a/include/ccustio.c b/include/ccustio.c index 6bd71543d..918dce2c4 100755 --- a/include/ccustio.c +++ b/include/ccustio.c @@ -59,25 +59,24 @@ semres : flag per l'ok delle operazioni sui semafori BOOLEAN test_share() { - static BOOLEAN share_active = TRUE; #ifdef DOS - static BOOLEAN to_test = TRUE; + static BOOLEAN share_active = 2; - if (to_test) + if (share_active == 2) { - to_test = FALSE; - share_active = CGetAut(MUAUT); if (share_active) { - int f = sopen("net.ini", O_RDONLY, SH_DENYNO, S_IREAD); + int f = open("net.ini", O_RDONLY, SH_DENYNO, S_IREAD); share_active = f != -1; if (f != -1) close(f); } } -#endif return share_active; +#else + return TRUE; +#endif }