From: elinuxhenrik Date: Tue, 2 Nov 2021 08:19:26 +0000 (+0100) Subject: Add error info to certificate create problem info X-Git-Tag: 1.2.0~57 X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F75%2F6975%2F1;p=nonrtric.git Add error info to certificate create problem info Issue-ID: NONRTRIC-601 Signed-off-by: elinuxhenrik Change-Id: I90f71faeac7749c4b6a1674011ce8e1dfc51e663 --- diff --git a/dmaap-mediator-producer/main.go b/dmaap-mediator-producer/main.go index cdfde579..e8689bd4 100644 --- a/dmaap-mediator-producer/main.go +++ b/dmaap-mediator-producer/main.go @@ -88,7 +88,7 @@ func createClientCertificate() (*tls.Certificate, error) { if cert, err := tls.LoadX509KeyPair(configuration.ProducerCertPath, configuration.ProducerKeyPath); err == nil { return &cert, nil } else { - return nil, fmt.Errorf("cannot create x509 keypair from cert file %s and key file %s", configuration.ProducerCertPath, configuration.ProducerKeyPath) + return nil, fmt.Errorf("cannot create x509 keypair from cert file %s and key file %s due to: %v", configuration.ProducerCertPath, configuration.ProducerKeyPath, err) } }