By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
428,759 Members | 1,727 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 428,759 IT Pros & Developers. It's quick & easy.

Simply gcc compilation error using sys/dir.h

P: n/a
compiling this using
gcc -o xxx xxx.c

I obtain this error message in function Main
6 storage size of 'ff' isn't known

Can any help me ?
#include <stdio.h>
#include <sys/dir.h>

int main (int argc, char* argv[])
{
struct ffblk ff;
int rc;
rc = findfirst ("*.*", &ff, ~0);
while (rc)
{
printf ("%s\n", ff.fa_name);
rc = findnext (&ff);
}
return 0;
}
Jul 19 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
> compiling this using
gcc -o xxx xxx.c

I obtain this error message in function Main
6 storage size of 'ff' isn't known

Can any help me ?
Not here.
#include <stdio.h>
Non standard

# include <cstdio>
#include <sys/dir.h>
Non standard.
int main (int argc, char* argv[])
{
struct ffblk ff;


What is ffblk?

<snip>

Please, I suspect <sys/dir.h> being an implementation specific
header. Ask in the newgroup supporting that implementation.

http://www.parashift.com/c++-faq-lit...t.html#faq-5.9
Jonathan
Jul 19 '05 #2

P: n/a
Jonathan Mcdougall wrote:
#include <stdio.h>

Non standard


According to D.5 it is standard (but deprecated).

-Kevin
--
My email address is valid, but changes periodically.
To contact me please use the address from a recent posting.

Jul 19 '05 #3

P: n/a
>> #include <stdio.h>

Non standard

# include <cstdio>
#include <sys/dir.h>


Non standard.
int main (int argc, char* argv[])
{
struct ffblk ff;


What is ffblk?


Excuse me, i'm using Gcc where can i find correct 'standard'
libraries? name and structures documentation?
To read directory tree and make a directory whot is the correct
library to use (under Linux using gcc)?

Thank's
----------------------------------------------------------
Paolo Hölzl
Gruppo Tekup Software developer (Bologna)
----------------------------------------------------------
ATTENTION!, antispam
For reply, substitute xxx with gruppotekup
Jul 19 '05 #4

P: n/a
On Wed, 08 Oct 2003 08:07:40 GMT, so******@xxx.com (Paolo Holzl) wrote:
#include <stdio.h>


Non standard

# include <cstdio>
#include <sys/dir.h>


Non standard.
int main (int argc, char* argv[])
{
struct ffblk ff;


What is ffblk?


Excuse me, i'm using Gcc where can i find correct 'standard'
libraries? name and structures documentation?
To read directory tree and make a directory whot is the correct
library to use (under Linux using gcc)?


That's off-topic in this group, try a gnu group.

But not-quite-offtopic, also take a look at <url:http//www.boost.org>. Reason
it's not quite offtopic: much of it will probably end up in the next standard.

Jul 19 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.