#include <sys/stat.h> struct stat sb; if (stat(pathname, &sb) == 0 && S_ISDIR(sb.st_mode)) { ...it is a directory... }
沒有留言:
張貼留言