mount: fix bug where target mountpoint would not be used

Signed-off-by: Hiltjo Posthuma <hiltjo@codemadness.org>
This commit is contained in:
Hiltjo Posthuma 2014-03-15 19:46:36 +01:00 committed by sin
parent a056e2aa54
commit bd994c3a50
1 changed files with 2 additions and 1 deletions

View File

@ -135,8 +135,9 @@ main(int argc, char *argv[])
strcmp(me->mnt_fsname, target) == 0 ||
(source && strcmp(me->mnt_dir, source) == 0) ||
(source && strcmp(me->mnt_fsname, source) == 0)) {
if(!source)
target = me->mnt_dir;
source = me->mnt_fsname;
target = me->mnt_dir;
if(!oflag)
parseopts(me->mnt_opts, &flags, data, datasiz);
if(!types)