🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.os.netware.misc
Article #590

Re: How to delete a directory quickly?

#590
From: Markus Borst
Date: Tue, 05 Sep 1995 00:00
28 lines
1988 bytes
A. Grant (ag129@cam.ac.uk) wrote:
> I am trying to delete a directory (that's the file type, not the
> NDS type!) via the NetWare API.  The 'delete directory' call won't
> let me delete a directory that isn't empty.
> 
> What am I doing at the moment is scanning for subdirectories, 
> deleting those recursively, then deleting the files in the directory,
> which I can do in one go using wildcards -- except that it may fail
> because some files are flagged non-deletable, then I have to scan
> all the files individually and change their flags.
> 
> Is there a better way?  How can I get the tree deleted in a minimum
> number of NCP interactions that doesn't involve all that network
> traffic to scan the tree?  Is there a way to handle the read-only
> flags problem?

Well, as far as I know, there is no quick way (but I'm not a
programmer), but you can surely save time, by just setting all files to
read-write, instead of checking first if they are read-only. They are
going to be deleted anyway, so why bother how they looked beforehand.

Bye
Markus
-- 
Markus Borst                             |In the beginning the Universe was
borst@rbg.informatik.th-darmstadt.de     |created. This has made a lot of
borst@bwl.bwl.th-darmstadt.de (temporary)|people very angry and been
                                         |widely regarded as a bad move.
Technical Details
Message-ID: <42hi1f$10ar@rs18.hrz.th-darmstadt.de>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <ag129.2260.000C33B2@cam.ac.uk>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: fe659,9e54e13477de5037
X-Google-Attributes: gidfe659,public
X-Google-Thread: f8bf7,9e54e13477de5037
X-Google-Attributes: gidf8bf7,public
From: borst@hp66.rbg.informatik.th-darmstadt.de (Markus Borst)
Subject: Re: How to delete a directory quickly?
Date: 1995/09/05
Message-ID: <42hi1f$10ar@rs18.hrz.th-darmstadt.de>
X-Deja-AN: 109538245
references: <ag129.2260.000C33B2@cam.ac.uk>
followup-to: comp.os.netware.misc,bit.listserv.novell
organization: Technische Hochschule Darmstadt
newsgroups: comp.os.netware.misc,bit.listserv.novell