mirror of
https://github.com/sheumann/hush.git
synced 2024-12-23 05:29:58 +00:00
Fixed a warning about a label not being used
This commit is contained in:
parent
8237add8d0
commit
3a0f4baf2f
@ -483,8 +483,10 @@ static int list_item(const char *name)
|
|||||||
lstat(fullname, &cur->dstat); /* get file stat info into node */
|
lstat(fullname, &cur->dstat); /* get file stat info into node */
|
||||||
dnp[ni++]= cur; /* save pointer to node in array */
|
dnp[ni++]= cur; /* save pointer to node in array */
|
||||||
#else
|
#else
|
||||||
if (lstat(fullname, &info))
|
if (lstat(fullname, &info)) {
|
||||||
goto direrr; /* (shouldn't fail) */
|
closedir(dir);
|
||||||
|
goto listerr; /* (shouldn't fail) */
|
||||||
|
}
|
||||||
list_single(entry->d_name, &info, fullname);
|
list_single(entry->d_name, &info, fullname);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
@ -504,8 +506,6 @@ static int list_item(const char *name)
|
|||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
direrr:
|
|
||||||
closedir(dir);
|
|
||||||
listerr:
|
listerr:
|
||||||
newline();
|
newline();
|
||||||
perror(name);
|
perror(name);
|
||||||
|
8
ls.c
8
ls.c
@ -483,8 +483,10 @@ static int list_item(const char *name)
|
|||||||
lstat(fullname, &cur->dstat); /* get file stat info into node */
|
lstat(fullname, &cur->dstat); /* get file stat info into node */
|
||||||
dnp[ni++]= cur; /* save pointer to node in array */
|
dnp[ni++]= cur; /* save pointer to node in array */
|
||||||
#else
|
#else
|
||||||
if (lstat(fullname, &info))
|
if (lstat(fullname, &info)) {
|
||||||
goto direrr; /* (shouldn't fail) */
|
closedir(dir);
|
||||||
|
goto listerr; /* (shouldn't fail) */
|
||||||
|
}
|
||||||
list_single(entry->d_name, &info, fullname);
|
list_single(entry->d_name, &info, fullname);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
@ -504,8 +506,6 @@ static int list_item(const char *name)
|
|||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
direrr:
|
|
||||||
closedir(dir);
|
|
||||||
listerr:
|
listerr:
|
||||||
newline();
|
newline();
|
||||||
perror(name);
|
perror(name);
|
||||||
|
Loading…
Reference in New Issue
Block a user