summaryrefslogtreecommitdiffstats
path: root/sys-apps/util-linux/files/util-linux-2.12q-update-mtab-when-moving.patch
diff options
context:
space:
mode:
authorSuren A. Chilingaryan <csa@suren.me>2019-09-02 05:23:45 +0200
committerSuren A. Chilingaryan <csa@suren.me>2019-09-02 05:23:45 +0200
commit576b6208d6defe240bfa2477d6dd19f1ed83bfaf (patch)
tree7d54883f16cccc4cbd414398d7fec3c437b36b49 /sys-apps/util-linux/files/util-linux-2.12q-update-mtab-when-moving.patch
parentfdd6b67a78a966f6a2131de8fe0e539316511083 (diff)
downloaddarklin4-576b6208d6defe240bfa2477d6dd19f1ed83bfaf.tar.gz
darklin4-576b6208d6defe240bfa2477d6dd19f1ed83bfaf.tar.bz2
darklin4-576b6208d6defe240bfa2477d6dd19f1ed83bfaf.tar.xz
darklin4-576b6208d6defe240bfa2477d6dd19f1ed83bfaf.zip
Cleaned most of outdated stuff
Diffstat (limited to 'sys-apps/util-linux/files/util-linux-2.12q-update-mtab-when-moving.patch')
-rw-r--r--sys-apps/util-linux/files/util-linux-2.12q-update-mtab-when-moving.patch33
1 files changed, 0 insertions, 33 deletions
diff --git a/sys-apps/util-linux/files/util-linux-2.12q-update-mtab-when-moving.patch b/sys-apps/util-linux/files/util-linux-2.12q-update-mtab-when-moving.patch
deleted file mode 100644
index aa921f5..0000000
--- a/sys-apps/util-linux/files/util-linux-2.12q-update-mtab-when-moving.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-Running `mount --move /foo /bar` would leave the old /foo entry in /etc/mtab
-and create a new /bar entry with wrong info.
-
-http://bugs.gentoo.org/104697
-
---- 1/mount/mount.c
-+++ 2/mount/mount.c
-@@ -665,6 +665,25 @@
- else {
- mntFILE *mfp;
-
-+ /* when moving a mount point, we have to make sure the mtab
-+ * gets updated properly. We get info about the old mount
-+ * point, copy it to the new mount point, and then delete
-+ * the old mount point. */
-+ if (flags & MS_MOVE) {
-+ const char *olddir = mnt.mnt_fsname;
-+ struct mntentchn *oldmc = oldmc = getmntfile(olddir);
-+ if (oldmc != NULL) {
-+ mnt.mnt_fsname = xstrdup(oldmc->m.mnt_fsname);
-+ mnt.mnt_type = oldmc->m.mnt_type;
-+ mnt.mnt_opts = oldmc->m.mnt_opts;
-+ mnt.mnt_freq = oldmc->m.mnt_freq;
-+ mnt.mnt_passno = oldmc->m.mnt_passno;
-+ }
-+ update_mtab(olddir, NULL);
-+ if (oldmc != NULL)
-+ my_free(olddir);
-+ }
-+
- lock_mtab();
- mfp = my_setmntent(MOUNTED, "a+");
- if (mfp == NULL || mfp->mntent_fp == NULL) {