Mail Archives: djgpp/1997/07/01/22:14:53
Why bother posting code without checking it! The person who asked the
questin is obviously a novice programmer - or newbie to djgpp
otherwise they would not have posted such a simple request
Here is the code that works and does not have a void return type.
#include <stdio.h>
#include <dir.h>
int main(int argc, char *argv[])
{
struct ffblk ff;
int done;
done=findfirst(argv[1],&ff,0);
while(!done)
{
printf("%s\n",ff.ff_name);
done=findnext(&ff);
}
return 0;
}
------------------------------------------------------------
Paul Whitfield !
Senior Software Engineer ! No Amusing Quote currently
Mits WA Limited ! available ...
Email: paulw AT mitswa DOT com DOT au !
- Raw text -