N
Nomen Nescio
BTW, mattia, I noticed you did post to comp.unix.programmer
quite a number of hours ago and got only two replies, and
those two replies were from people who are also on this
newsgroup, strangely enough.
Viza, who's a good fellow, told you to "man opendir" and
"man readdir", which is pretty much the same advice you got
on this newsgroup, except that on this newsgroup you also
got told about closedir().
Ben Bacarisse told you about the useful scandir() function,
but if you'd included comp.lang.c in your post, people here
could've added the possibly important detail that scandir()
isn't a POSIX function (though is being considered for a future
POSIX release).
This simply bolsters the argument that you're going to get
better advice if you cross-post to BOTH comp.lang.c AND
comp.unix.programmer.
Yours,
Han from China
quite a number of hours ago and got only two replies, and
those two replies were from people who are also on this
newsgroup, strangely enough.
Viza, who's a good fellow, told you to "man opendir" and
"man readdir", which is pretty much the same advice you got
on this newsgroup, except that on this newsgroup you also
got told about closedir().
Ben Bacarisse told you about the useful scandir() function,
but if you'd included comp.lang.c in your post, people here
could've added the possibly important detail that scandir()
isn't a POSIX function (though is being considered for a future
POSIX release).
This simply bolsters the argument that you're going to get
better advice if you cross-post to BOTH comp.lang.c AND
comp.unix.programmer.
Yours,
Han from China