mirror of
https://github.com/parchlinux/calamares.git
synced 2025-06-29 10:25:36 -04:00
Check for fs name validity.
This commit is contained in:
parent
37426b9f7a
commit
8ce769184e
1 changed files with 7 additions and 1 deletions
|
@ -143,7 +143,9 @@ class UnpackOperation:
|
||||||
subprocess.check_call(["mount",
|
subprocess.check_call(["mount",
|
||||||
entry.source,
|
entry.source,
|
||||||
imgmountdir,
|
imgmountdir,
|
||||||
"-t", entry.sourcefs, "-o", "loop"])
|
"-t",
|
||||||
|
entry.sourcefs,
|
||||||
|
"-o", "loop"])
|
||||||
|
|
||||||
def unpack_image(self, entry, imgmountdir):
|
def unpack_image(self, entry, imgmountdir):
|
||||||
def progress_cb(copied):
|
def progress_cb(copied):
|
||||||
|
@ -186,7 +188,11 @@ def run():
|
||||||
|
|
||||||
for entry in job.configuration["unpack"]:
|
for entry in job.configuration["unpack"]:
|
||||||
source = os.path.abspath(entry["source"])
|
source = os.path.abspath(entry["source"])
|
||||||
|
|
||||||
sourcefs = entry["sourcefs"]
|
sourcefs = entry["sourcefs"]
|
||||||
|
if sourcefs not in ["ext4", "squashfs"]:
|
||||||
|
return "Bad filesystem", "sourcefs=\"{}\"".format(sourcefs)
|
||||||
|
|
||||||
destination = os.path.abspath(root_mount_point + entry["destination"])
|
destination = os.path.abspath(root_mount_point + entry["destination"])
|
||||||
|
|
||||||
if not os.path.isfile(source):
|
if not os.path.isfile(source):
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue