mirror of
https://github.com/jarun/nnn.git
synced 2024-11-28 05:41:31 +00:00
Rename testopendir() to canopendir()
This commit is contained in:
parent
48f9c5a79d
commit
789f9336f4
10
noice.c
10
noice.c
|
@ -396,7 +396,7 @@ readln(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
testopendir(char *path)
|
canopendir(char *path)
|
||||||
{
|
{
|
||||||
DIR *dirp;
|
DIR *dirp;
|
||||||
|
|
||||||
|
@ -615,7 +615,7 @@ nochange:
|
||||||
/* There is no going back */
|
/* There is no going back */
|
||||||
if (strcmp(path, "/") == 0)
|
if (strcmp(path, "/") == 0)
|
||||||
goto nochange;
|
goto nochange;
|
||||||
if (testopendir(path) == 0) {
|
if (canopendir(path) == 0) {
|
||||||
printwarn();
|
printwarn();
|
||||||
goto nochange;
|
goto nochange;
|
||||||
}
|
}
|
||||||
|
@ -646,7 +646,7 @@ nochange:
|
||||||
|
|
||||||
switch (sb.st_mode & S_IFMT) {
|
switch (sb.st_mode & S_IFMT) {
|
||||||
case S_IFDIR:
|
case S_IFDIR:
|
||||||
if (testopendir(path) == 0) {
|
if (canopendir(path) == 0) {
|
||||||
printwarn();
|
printwarn();
|
||||||
goto nochange;
|
goto nochange;
|
||||||
}
|
}
|
||||||
|
@ -705,7 +705,7 @@ nochange:
|
||||||
clearprompt();
|
clearprompt();
|
||||||
goto nochange;
|
goto nochange;
|
||||||
}
|
}
|
||||||
if (testopendir(tmp) == 0) {
|
if (canopendir(tmp) == 0) {
|
||||||
printwarn();
|
printwarn();
|
||||||
goto nochange;
|
goto nochange;
|
||||||
}
|
}
|
||||||
|
@ -753,7 +753,7 @@ main(int argc, char *argv[])
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Test initial path */
|
/* Test initial path */
|
||||||
if (testopendir(ipath) == 0)
|
if (canopendir(ipath) == 0)
|
||||||
printerr(1, ipath);
|
printerr(1, ipath);
|
||||||
|
|
||||||
/* Set locale before curses setup */
|
/* Set locale before curses setup */
|
||||||
|
|
Loading…
Reference in a new issue