From cd69645b3275b92e62d97786e671874486e5d446 Mon Sep 17 00:00:00 2001 From: Arndt Kaiser Date: Mon, 11 May 2020 08:20:04 +0200 Subject: [PATCH] Function set_pass() now returns 0 on success in batch-mode If changing passwords in batch-mode, the commands set-rsa-pass and set-ec-pass allways returned with an exit code != 0 on success. The origin for this is the implementation of the function notice() which allway returns an return-code != 0 if called in batch-mode. This patch fixes the bug by adding a return 0 at the end of set_pass(), because this is the way this behaviour is fixed in other functions. I will provide an additional pull-request to improve the functions notice() and warn(). --- easyrsa3/easyrsa | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/easyrsa3/easyrsa b/easyrsa3/easyrsa index 2e5d13b..bb522f0 100755 --- a/easyrsa3/easyrsa +++ b/easyrsa3/easyrsa @@ -1486,7 +1486,8 @@ error messages." Failed to change the private key passphrase. See above for error messages." notice "Key passphrase successfully changed" - + + return 0 } # => set_pass() # update-db backend