From: Denis Vlasenko Date: Thu, 14 Sep 2006 16:09:27 +0000 (-0000) Subject: mount: -o remount should not add lines to /etc/mtab X-Git-Tag: 1_4_0~688 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=be507170eb151ed06685e0e8de2fe1af2fedd374;p=oweals%2Fbusybox.git mount: -o remount should not add lines to /etc/mtab --- diff --git a/util-linux/mount.c b/util-linux/mount.c index 5592a7a5f..4660b27ef 100644 --- a/util-linux/mount.c +++ b/util-linux/mount.c @@ -222,7 +222,7 @@ static int mount_it_now(struct mntent *mp, int vfsflags, char *filteropts) /* If the mount was successful, and we're maintaining an old-style * mtab file by hand, add the new entry to it now. */ - if(ENABLE_FEATURE_MTAB_SUPPORT && useMtab && !rc) { + if(ENABLE_FEATURE_MTAB_SUPPORT && useMtab && !rc && !(vfsflags & MS_REMOUNT)) { char dirbuf[PATH_MAX]; char srcbuf[PATH_MAX]; FILE *mountTable = setmntent(bb_path_mtab_file, "a+");