2018-11-18 00:28:23 +08:00
|
|
|
#include <glob.h>
|
|
|
|
|
|
|
|
int glob_error(const char *epath, int errno)
|
|
|
|
{
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
int main()
|
|
|
|
{
|
|
|
|
glob_t files;
|
|
|
|
const char *pattern = "*";
|
|
|
|
glob(pattern, GLOB_MARK, glob_error, &files);
|
|
|
|
globfree(&files);
|
2018-11-18 00:55:07 +08:00
|
|
|
return 0;
|
2018-11-18 00:28:23 +08:00
|
|
|
}
|