From: Arvin Schnell Date: Thu, 30 Aug 2012 10:19:07 +0000 (+0200) Subject: - mount snapshot with nodev X-Git-Tag: v0.1.3~129 X-Git-Url: http://git.ipfire.org/gitweb/index.cgi?a=commitdiff_plain;h=b464b21b551b9baaeb76f7be0f04544ffc24ddaa;p=thirdparty%2Fsnapper.git - mount snapshot with nodev --- diff --git a/snapper/Filesystem.cc b/snapper/Filesystem.cc index 62fe7e7e..e3a03dfe 100644 --- a/snapper/Filesystem.cc +++ b/snapper/Filesystem.cc @@ -73,10 +73,12 @@ namespace snapper vector filter_mount_options(vector& options) { - static const char* ign_opt[] = { "ro", "rw", "suid", "nosuid", "exec", "noexec", - "atime", "noatime", "diratime", "nodiratime", - "relatime", "norelatime", "strictatime", - "nostrictatime" }; + static const char* ign_opt[] = { + "ro", "rw", + "exec", "noexec", "suid", "nosuid", "dev", "nodev", + "atime", "noatime", "diratime", "nodiratime", + "relatime", "norelatime", "strictatime", "nostrictatime" + }; vector ret = options; @@ -90,7 +92,8 @@ namespace snapper bool mount(const string& device, int fd, const string& mount_type, const vector& options) { - unsigned long mount_flags = MS_RDONLY | MS_NOATIME | MS_NODIRATIME | MS_NOEXEC | MS_NOSUID; + unsigned long mount_flags = MS_RDONLY | MS_NOEXEC | MS_NOSUID | MS_NODEV | + MS_NOATIME | MS_NODIRATIME; string mount_data = boost::join(options, ",");