From: Arvin Schnell Date: Thu, 4 Aug 2011 15:55:37 +0000 (+0200) Subject: - canonicalize subvolume X-Git-Tag: v0.1.3~316 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=87a35e34c9b98619e28cd569dccc664ecef75acb;p=thirdparty%2Fsnapper.git - canonicalize subvolume --- diff --git a/tools/snapper.cc b/tools/snapper.cc index 2069e631..17ec6740 100644 --- a/tools/snapper.cc +++ b/tools/snapper.cc @@ -131,7 +131,12 @@ command_create_config() exit(EXIT_FAILURE); } - string subvolume = getopts.popArg(); + string subvolume = realpath(getopts.popArg()); + if (subvolume.empty()) + { + cerr << _("Invalid subvolume.") << endl; + exit(EXIT_FAILURE); + } string fstype = ""; string template_name = "default";