Unix Programming - read directory contents

This is Interesting: Free IT Magazines  
Home > Archive > Unix Programming > May 2007 > read directory contents





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author read directory contents
Mr. X.

2007-05-31, 7:24 pm

Hello,
How can I read the directory contents (files), in C (Linux) ?

This - using file descriptor, after openning the directory.

Thanks


moi

2007-05-31, 7:24 pm

On Thu, 31 May 2007 22:47:25 +0300, Mr. X. wrote:

> Hello,
> How can I read the directory contents (files), in C (Linux) ?
>
> This - using file descriptor, after openning the directory.
>
> Thanks


man 3 opendir
man 3 readdir

HTH,
AvK
David Schwartz

2007-05-31, 7:24 pm

On May 31, 12:47 pm, "Mr. X." <no_spam_please@nospam_please.com>
wrote:
> Hello,
> How can I read the directory contents (files), in C (Linux) ?
>
> This - using file descriptor, after openning the directory.
>
> Thanks


If you are absolutely sure this really is what you want to do, 'man 2
getdents'.

DS

moi

2007-05-31, 7:24 pm

On Thu, 31 May 2007 15:00:55 -0700, David Schwartz wrote:

> On May 31, 12:47 pm, "Mr. X." <no_spam_please@nospam_please.com>
> wrote:
>
> If you are absolutely sure this really is what you want to do, 'man 2
> getdents'.
>


man 3p looseteeth

:-)

AvK
Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com