version 1.166, 2020/10/18 12:47:43 |
version 1.167, 2020/10/18 13:02:10 |
Line 227 typedef struct OpenDirs { |
|
Line 227 typedef struct OpenDirs { |
|
static void |
static void |
OpenDirs_Init(OpenDirs *odirs) |
OpenDirs_Init(OpenDirs *odirs) |
{ |
{ |
odirs->list = Lst_Init(); |
odirs->list = Lst_New(); |
Hash_InitTable(&odirs->table); |
Hash_InitTable(&odirs->table); |
} |
} |
|
|
Line 392 cached_lstat(const char *pathname, struc |
|
Line 392 cached_lstat(const char *pathname, struc |
|
void |
void |
Dir_Init(void) |
Dir_Init(void) |
{ |
{ |
dirSearchPath = Lst_Init(); |
dirSearchPath = Lst_New(); |
OpenDirs_Init(&openDirs); |
OpenDirs_Init(&openDirs); |
Hash_InitTable(&mtimes); |
Hash_InitTable(&mtimes); |
Hash_InitTable(&lmtimes); |
Hash_InitTable(&lmtimes); |
Line 883 Dir_Expand(const char *word, SearchPath |
|
Line 883 Dir_Expand(const char *word, SearchPath |
|
char *dp = &dirpath[strlen(dirpath) - 1]; |
char *dp = &dirpath[strlen(dirpath) - 1]; |
if (*dp == '/') |
if (*dp == '/') |
*dp = '\0'; |
*dp = '\0'; |
path = Lst_Init(); |
path = Lst_New(); |
(void)Dir_AddDir(path, dirpath); |
(void)Dir_AddDir(path, dirpath); |
DirExpandInt(cp + 1, path, expansions); |
DirExpandInt(cp + 1, path, expansions); |
Lst_Free(path); |
Lst_Free(path); |