projects
/
prosody.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5f5f9fb
)
prosodyctl: Show real error if certificate config file can't be opened
author
Kim Alvefur
<zash@zash.se>
Sat, 22 Mar 2014 11:02:11 +0000
(12:02 +0100)
committer
Kim Alvefur
<zash@zash.se>
Sat, 22 Mar 2014 11:02:11 +0000
(12:02 +0100)
prosodyctl
patch
|
blob
|
history
diff --git
a/prosodyctl
b/prosodyctl
index 247b099a94f73a30109a7139e45103a9fe32332f..d341a75bbabb7a5e131626e80f6628df85ff74b0 100755
(executable)
--- a/
prosodyctl
+++ b/
prosodyctl
@@
-684,7
+684,12
@@
function cert_commands.config(arg)
conf.distinguished_name[k] = nv ~= "." and nv or nil;
end
end
- local conf_file = io.open(conf_filename, "w");
+ local conf_file, err = io.open(conf_filename, "w");
+ if not conf_file then
+ show_warning("Could not open OpenSSL config file for writing");
+ show_warning(err);
+ os.exit(1);
+ end
conf_file:write(conf:serialize());
conf_file:close();
print("");