From 6317d2fc4d161ab5f504cac0ac9620994829de62 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Felix=20D=C3=B6rre?= Date: Thu, 30 Jun 2016 10:29:06 +0200 Subject: [PATCH] minifixes --- src/apps/client.cpp | 5 +++-- src/util.cpp | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/apps/client.cpp b/src/apps/client.cpp index bfb7fb1..9a7add6 100644 --- a/src/apps/client.cpp +++ b/src/apps/client.cpp @@ -166,8 +166,9 @@ int main( int argc, const char* argv[] ) { continue; } - logger::note( "FINE: CERTIFICATE LOG:\n", res->log ); - logger::note( "FINE: CERTIFICATE:\n", res->certificate ); + logger::note( "FINE: CERTIFICATE LOG:\n", res->log, + "FINE: CERTIFICATE:\n", res->certificate ); + std::string fn = writeBackFile( job->target.c_str(), res->certificate, keyDir ); if( fn.empty() ) { diff --git a/src/util.cpp b/src/util.cpp index 3197b68..30f87b7 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -29,7 +29,7 @@ std::string writeBackFile( const std::string& serial, const std::string& cert, c if( 0 != mkdir( filename.c_str(), 0755 ) ) { if( EEXIST != errno ) { - return ""; + throw std::runtime_error("Storage location could not be determined"); } //! \FIXME: Check this is a directory -- 2.39.2