[M3devel] rmrec problems
Jay K
jay.krell at cornell.edu
Fri Jul 30 15:23:43 CEST 2010
Better theory: readdir uses globals. Suggest readdir_r...
- Jay
----------------------------------------
> From: jay.krell at cornell.edu
> To: wagner at elegosoft.com; m3devel at elegosoft.com
> Subject: rmrec problems
> Date: Fri, 30 Jul 2010 13:20:40 +0000
>
>
> Olaf, I suggest that maybe deleting while enumerating is undefined?
> We should try enumerating first, and then deleting, at least on a per-directory basis, not recursively.
> Even though that is bad in terms of working set -- small constant to unbounded.
>
>
> As well, recursion on the machine stack that is bounded by user input, is to be avoided.
> User can provide arbitrarily deep input and you blow the stack.
> Better to use a queue or stack data structure, add elements, and loop while not empty.
>
>
> I can try something here within a week, we can see if it helps.
>
>
> Stopgap might be to double up the rmrec calls and see what happens.
> Maybe delete while enumerate works under some conditions.
>
>
> Maybe I'm just randomly guessing (yes) and am way off (unknown).
>
> - Jay
>
>
>
>
>
More information about the M3devel
mailing list