mirror of
https://github.com/sheumann/hush.git
synced 2025-01-31 03:34:10 +00:00
umount: fix fallout from stack reduction change
This commit is contained in:
parent
f882f08627
commit
ef36c04ccf
@ -62,7 +62,7 @@ int umount_main(int argc, char **argv)
|
|||||||
if (opt & OPT_ALL)
|
if (opt & OPT_ALL)
|
||||||
bb_error_msg_and_die("cannot open %s", bb_path_mtab_file);
|
bb_error_msg_and_die("cannot open %s", bb_path_mtab_file);
|
||||||
} else {
|
} else {
|
||||||
while (getmntent_r(fp, &me, path, sizeof(path))) {
|
while (getmntent_r(fp, &me, path, PATH_MAX)) {
|
||||||
/* Match fstype if passed */
|
/* Match fstype if passed */
|
||||||
if (fstype && match_fstype(&me, fstype))
|
if (fstype && match_fstype(&me, fstype))
|
||||||
continue;
|
continue;
|
||||||
@ -89,7 +89,7 @@ int umount_main(int argc, char **argv)
|
|||||||
|
|
||||||
// Do we already know what to umount this time through the loop?
|
// Do we already know what to umount this time through the loop?
|
||||||
if (m)
|
if (m)
|
||||||
safe_strncpy(path, m->dir, sizeof(path));
|
safe_strncpy(path, m->dir, PATH_MAX);
|
||||||
// For umount -a, end of mtab means time to exit.
|
// For umount -a, end of mtab means time to exit.
|
||||||
else if (opt & OPT_ALL)
|
else if (opt & OPT_ALL)
|
||||||
break;
|
break;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user