From 1bc3b5892e721c733f9e1710274fccd2538134e3 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Wed, 18 Sep 2013 15:48:02 +0000 Subject: [PATCH] -handle failure to load certs more nicely --- src/gns/gnunet-gns-proxy.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/gns/gnunet-gns-proxy.c b/src/gns/gnunet-gns-proxy.c index 21e907ebf..8bb299c6f 100644 --- a/src/gns/gnunet-gns-proxy.c +++ b/src/gns/gnunet-gns-proxy.c @@ -1764,9 +1764,8 @@ load_key_from_file (gnutls_x509_privkey_t key, GNUNET_log (GNUNET_ERROR_TYPE_ERROR, _("Unable to import private key from file `%s'\n"), keyfile); - GNUNET_break (0); } - GNUNET_free (key_data.data); + GNUNET_free_non_null (key_data.data); return (GNUTLS_E_SUCCESS != ret) ? GNUNET_SYSERR : GNUNET_OK; } @@ -1792,9 +1791,8 @@ load_cert_from_file (gnutls_x509_crt_t crt, { GNUNET_log (GNUNET_ERROR_TYPE_ERROR, _("Unable to import certificate %s\n"), certfile); - GNUNET_break (0); } - GNUNET_free (cert_data.data); + GNUNET_free_non_null (cert_data.data); return (GNUTLS_E_SUCCESS != ret) ? GNUNET_SYSERR : GNUNET_OK; } -- 2.25.1