[PATCH v4 02/16] keytoc: fail in case gen_key() fails

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



In case of an error in gen_key() return an error code so that the keytoc
tool returns an error.

Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx>
---
 scripts/keytoc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/keytoc.c b/scripts/keytoc.c
index 3ac42bc6d0..7e73c786a3 100644
--- a/scripts/keytoc.c
+++ b/scripts/keytoc.c
@@ -597,7 +597,7 @@ static int gen_key(const char *keyname, const char *path)
 	if (ret)
 		ret = gen_key_rsa(key, keyname, key_name_c);
 
-	return 0;
+	return ret;
 }
 
 int main(int argc, char *argv[])
-- 
2.39.2





[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux