mwm@raven.pa.dec.com (Mike (With friends like these, who needs hallucinations) Meyer) (01/03/90)
>> If you can get around using a recursive function then by all means so >> so. I had a routine that scanned a dir and did various things that >> needed a stack of 30k to work with my HD (I have some rather sever >> levels of directory depth in some places...). I re-wrote the routine >> inside a big for(;;) {} loop adding a couple of variables to make it >> `think' it was recursive and now the same program will work just dandy >> with a 4000 byte stack (the AmigaDOS default). I wrote a generic non-recursive routine for walking file trees a while back. It's modelled after the ftw & ftwalk routines from Unix. Last time I looked, it could be ftp'ed off of ucbvax.berkeley.edu, along with a command-line interface modelled after ftw from v8, complete with ARexx interface and sample scripts. There are also some timings of a beta version against programs with hand-coded file tree walking routines. The file was pub/amiga/treewalk.tar.Z. <mike -- Come all you rolling minstrels, Mike Meyer And together we will try, mwm@berkeley.edu To rouse the spirit of the air, ucbvax!mwm And move the rolling sky. mwm@ucbjade.BITNET