home: hub: mkinitfs

Download patch

ref: fdd4ec67ab691c8d6c31986239a2a4c409128bea
parent: 5ee279f6b475306659af256f724847c65b335040
author: 7heo <7heo@mail.com>
date: Thu Sep 15 20:39:41 CDT 2016

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.

--- a/nlplug-findfs.c
+++ b/nlplug-findfs.c
@@ -586,6 +586,12 @@
 		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];