]> git.ipfire.org Git - thirdparty/samba.git/commit
mount.cifs: use lock/unlock_mtab scheme from util-linux-ng mount prog
authorJeff Layton <jlayton@redhat.com>
Thu, 6 Nov 2008 20:20:55 +0000 (15:20 -0500)
committerKarolin Seeger <kseeger@samba.org>
Mon, 12 Jan 2009 09:11:57 +0000 (10:11 +0100)
commite1cce62024545be0b8439eb617a564bec72d9a8c
tree08d6580502cd59f5965dc94ac85abf53a78ff3d8
parent980e56109ba42703a658f6f983021843ddd06d16
mount.cifs: use lock/unlock_mtab scheme from util-linux-ng mount prog

The util-linux-ng sources have a good, but rather complex scheme for
locking the mtab before updating it. Mount helpers need to follow the
same scheme. Advisory locking only works if everyone is using the same
locking scheme.

Copy the routines we need from util-linux-ng into a separate source file
and then have mount.cifs and umount.cifs link in this object.

The long term goal is to have these routines in a separate helper
library (libmount). Mount helpers can then dynamically link in that lib.
Until that happens, this should serve as a suitable stopgap solution.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit 66ec780d878979a9fa33ff868f1849e9d2166dcf)
source/Makefile.in
source/client/mount.cifs.c
source/client/mount.h [new file with mode: 0644]
source/client/mtab.c [new file with mode: 0644]
source/client/umount.cifs.c