/*
 * dirent.h
 */


#ifndef dirent_h
#define dirent_h


#include<sys/types.h>
#include<limits.h>


typedef int DIR;

struct dirent{
	int  d_fileno;			/* file number of entry */
	int  d_namlen;
	char d_name[NAME_MAX];	/* Name of entry. */
};


extern inline int dirfd(DIR *dir)
{
	return (int)dir;
}

/* Functions. */
extern int            closedir(DIR *);;
extern DIR           *opendir(const char *);
extern struct dirent *readdir(DIR *);
extern void           rewinddir(DIR *);


#endif
