summaryrefslogtreecommitdiff
path: root/src/wx/config_dialog.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2016-08-25 14:42:37 +0100
committerCarl Hetherington <cth@carlh.net>2016-08-25 14:42:37 +0100
commitbb7917d2ea06e6eaa566b00a279e9b5a6a351fc9 (patch)
tree8354e0b83aa707c7ef8a50d6609e07787ec61554 /src/wx/config_dialog.cc
parente2d0781d45fccd67649a8943f1fb45442f5d2cbc (diff)
Take the leaf of a certificate chain if one is provided
for a screen certificate (#937).
Diffstat (limited to 'src/wx/config_dialog.cc')
-rw-r--r--src/wx/config_dialog.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/wx/config_dialog.cc b/src/wx/config_dialog.cc
index ac5d90296..0369070a7 100644
--- a/src/wx/config_dialog.cc
+++ b/src/wx/config_dialog.cc
@@ -773,8 +773,9 @@ private:
if (d->ShowModal() == wxID_OK) {
try {
- dcp::Certificate c (dcp::file_to_string (wx_to_std (d->GetPath ())));
- if (c.extra_data ()) {
+ dcp::Certificate c;
+ string const extra = c.read_string (dcp::file_to_string (wx_to_std (d->GetPath ())));
+ if (!extra.empty ()) {
message_dialog (
this,
_("This file contains other certificates (or other data) after its first certificate. "