diff options
author | 7heo <7heo@mail.com> | 2016-09-16 01:39:41 +0200 |
---|---|---|
committer | 7heo <7heo@mail.com> | 2017-04-05 12:13:36 +0200 |
commit | fdd4ec67ab691c8d6c31986239a2a4c409128bea (patch) | |
tree | 9e2dbd77d3bf43a53618e521a47500f46b4fece9 | |
parent | 5ee279f6b475306659af256f724847c65b335040 (diff) | |
download | mkinitfs-fdd4ec67ab691c8d6c31986239a2a4c409128bea.tar.bz2 mkinitfs-fdd4ec67ab691c8d6c31986239a2a4c409128bea.tar.xz |
nlplug-findfs: fix the deported header feature
Without a call to crypt_set_data_device(), the cryptsetup system does
not know where to find the data device. It works whether the header is
deported or not, according to
https://github.com/mbroz/cryptsetup/blob/8f84fb49faa69b0ddde3d534ee9c72119256f4c9/src/cryptsetup.c#L782
so it is fine to call it in all cases.
-rw-r--r-- | nlplug-findfs.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/nlplug-findfs.c b/nlplug-findfs.c index e89ab23..f23d0dd 100644 --- a/nlplug-findfs.c +++ b/nlplug-findfs.c @@ -586,6 +586,12 @@ static void *cryptsetup_thread(void *data) goto free_out; } + r = crypt_set_data_device(cd, data_devnode); + if (r < 0) { + warnx("crypt_set_data_device(%s)", data_devnode); + goto free_out; + } + while (passwd_tries > 0) { char pass[1024]; |