I want to check if file returned by readdir
is directory.
I tried do it using DT_DIR
constant (as man readdir
says) but it's undefined. What file should I include to get it?
Now I use
#include <sys/types.h>
#include <dirent.h>
#include <stdlib.h>
#include <errno.h>
gcc version is 4.6.1
Compilation string:
gcc a.c --std=c99 -Wall