#178671 - 2007-08-03 09:59 AM
RD /s doesn't seem to handle read-only directories.
|
Ryan
Fresh Scripter
Registered: 2001-11-11
Posts: 42
Loc: the Netherlands
|
Hi there,
It's seems that RD /s doesn't delete read-only directories. Version 4.53
Can someone else confirm this?
Situation 1: "C:\Temp\Test", Dir Test is read-only.
RD "C:\Temp\Test" /s ErrorCode: 5 Access is denied.
Situation 2: "C:\Temp\Test\Sub", Only Dir Sub is read-only.
RD "C:\Temp\Test\Sub" /s ErrorCode: 145 The directory is not empty.
Manual says it deletes everything, like CMD.EXE's RD /q /s does. I've tested it with, S and H attributes, and no problems. Only R attribute.
Thanx, Ryan
|
|
Top
|
|
|
|
#178676 - 2007-08-03 11:55 AM
Re: RD /s doesn't seem to handle read-only directories.
[Re: NTDOC]
|
Ryan
Fresh Scripter
Registered: 2001-11-11
Posts: 42
Loc: the Netherlands
|
He NTDoc,
Thanx for confirming and posting.
Looking forward on 4.60, nice features.
Grz Ryan
|
|
Top
|
|
|
|
#178709 - 2007-08-05 10:29 AM
Re: RD /s doesn't seem to handle read-only directories.
[Re: Glenn Barnas]
|
NTDOC
Administrator
   
Registered: 2000-07-28
Posts: 11634
Loc: Space
|
Well I'm actually of the opposite feeling on that. I'm tired of utils that refuse to delete and you have to go back and double check or run more commands, etc.
I said REMOVE - I don't care what is left in there or what attributes it has, REMOVE IT. If I was concerned with the attributes then I'd probably be using a DEL command and paying more attention. RD (IMHO) is and should be a quit asking, just remove command. I don't need or want the underlying OS or other items trying to out think me and "ARE YOU SURE" me till I'm blue in the face. I took the time to code it up, YES I'M SURE.
/end rant
|
|
Top
|
|
|
|
Moderator: Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart
|
0 registered
and 2220 anonymous users online.
|
|
|