diff --git a/libretroshare/src/pqi/authgpg.cc b/libretroshare/src/pqi/authgpg.cc index e6e2ee00b..2e3ab1c34 100644 --- a/libretroshare/src/pqi/authgpg.cc +++ b/libretroshare/src/pqi/authgpg.cc @@ -1230,7 +1230,7 @@ bool AuthGPG::LoadCertificateFromString(std::string str, std::string &gpg_id) if(res == NULL || res->imports == NULL) return false ; - std::string fingerprint = std::string(res->imports->fpr); + fingerprint = std::string(res->imports->fpr); #ifdef GPG_DEBUG std::cerr << "AuthGPG::LoadCertificateFromString() Importing considered folowing fpr : " << fingerprint << std::endl; #endif @@ -1264,8 +1264,11 @@ bool AuthGPG::LoadCertificateFromString(std::string str, std::string &gpg_id) #ifdef GPG_DEBUG std::cerr << "AuthGPG::LoadCertificateFromString() returning with gpg_id : " << gpg_id << std::endl; #endif - - return true; + if (gpg_id == "") { + return false; + } else { + return true; + } } /***************************************************************** diff --git a/libretroshare/src/rsserver/p3peers.cc b/libretroshare/src/rsserver/p3peers.cc index 718a016c4..c2a03e885 100644 --- a/libretroshare/src/rsserver/p3peers.cc +++ b/libretroshare/src/rsserver/p3peers.cc @@ -981,7 +981,11 @@ bool p3Peers::loadDetailsFromStringCert(std::string certstr, RsPeerDetails &pd) std::cerr << "ConnectFriendWizard : Parse ip address error." << std::endl; } - return true; + if (pd.gpg_id == "") { + return false; + } else { + return true; + } }