Re: directory traversal



Paul Davis wrote:
Jeff Abrahamson wrote:

I want to recursively traverse a directory. It seems dumb to write
this from scratch (and easy to goof on corner cases), but I haven't
found anything in glib / gtk / etc. that seems to address it. (Yeah,
this is more of a glib question than a gtk question, I guess.)


The following proglet exercises a function called read_directory(),
which traverses a directory. I often use it as a template for other
programs requiring this functionality. The section on file utility
functions in the Glib documentation may be worth a read as well.

man ftw


$ man ftw
man: no entry for ftw in the manual.
$ uname
NetBSD

I guess ftw must be some sort of SysV specific thing.

Chris

--
chris wareham iosystems co uk (work)
cwareham btinternet com (home)




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]