aboutsummaryrefslogtreecommitdiffstats
path: root/libqpdf/QPDFJob_argv.cc
diff options
context:
space:
mode:
authorJay Berkenbilt <ejb@ql.org>2023-12-23 02:09:31 +0100
committerJay Berkenbilt <ejb@ql.org>2023-12-23 02:10:21 +0100
commit1f4568684341ec3a0abb0c7ce72580b07b73d646 (patch)
tree652c54705bcf74b76a0923c11950f3a7e2c50cf6 /libqpdf/QPDFJob_argv.cc
parenta2c4a2b12a76bd932ba709d9c199a6f1684ba0be (diff)
downloadqpdf-1f4568684341ec3a0abb0c7ce72580b07b73d646.tar.zst
Handle --encrypt -- without crashing
Diffstat (limited to 'libqpdf/QPDFJob_argv.cc')
-rw-r--r--libqpdf/QPDFJob_argv.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/libqpdf/QPDFJob_argv.cc b/libqpdf/QPDFJob_argv.cc
index 56acd7a9..3875474b 100644
--- a/libqpdf/QPDFJob_argv.cc
+++ b/libqpdf/QPDFJob_argv.cc
@@ -163,6 +163,7 @@ ArgParser::argShowCrypto()
void
ArgParser::argEncrypt()
{
+ this->c_enc = c_main->encrypt(0, "", "");
this->accumulated_args.clear();
this->ap.selectOptionTable(O_ENCRYPTION);
}