Hi All,
I don't normally post patches to the list, but this one can avoid some
accidental file deletions. As it stands, the dos server can unlink() a
directory with files in it - it should only be able to unlink() empty
directories. I found this as I've just added an rmdir() function to libc -
there's an rmdir command to go with it.
The patch is to srv/dos/dir.c
Regards,
Dave
------------------------------------------------------------------------------
--- dir.c.orig Wed May 11 09:53:26 1994
+++ dir.c Tue May 24 13:41:25 1994
@@ -383,13 +383,13 @@
}
/*
* Oops. Found a file. Not empty.
*/
bfree(handle);
- return(1);
+ return(0);
}
bfree(handle);
}
return(1);
}
Received on Tue May 24 05:43:51 1994
This archive was generated by hypermail 2.1.8 : Wed Sep 21 2005 - 21:04:28 PDT