[hackers] [ubase] mount: fix bug where target mountpoint would not be used || Hiltjo Posthuma

From: <git_AT_suckless.org>
Date: Sat, 15 Mar 2014 20:30:07 +0100

commit bd994c3a507a326c95b04263be7d68ffce3f6409
Author: Hiltjo Posthuma <hiltjo_AT_codemadness.org>
Date: Sat Mar 15 19:46:36 2014 +0100

    mount: fix bug where target mountpoint would not be used
    
    Signed-off-by: Hiltjo Posthuma <hiltjo_AT_codemadness.org>

diff --git a/mount.c b/mount.c
index 338c69d..eda60ee 100644
--- a/mount.c
+++ b/mount.c
_AT_@ -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)
Received on Sat Mar 15 2014 - 20:30:07 CET

This archive was generated by hypermail 2.3.0 : Sat Mar 15 2014 - 20:36:26 CET