diff --git a/libretroshare/src/pgp/rscertificate.cc b/libretroshare/src/pgp/rscertificate.cc index 092660784..cdd004fc0 100644 --- a/libretroshare/src/pgp/rscertificate.cc +++ b/libretroshare/src/pgp/rscertificate.cc @@ -9,7 +9,7 @@ #include "rscertificate.h" #include "util/rsstring.h" -#define DEBUG_RSCERTIFICATE +//#define DEBUG_RSCERTIFICATE static const std::string PGP_CERTIFICATE_START ( "-----BEGIN PGP PUBLIC KEY BLOCK-----" ); static const std::string PGP_CERTIFICATE_END ( "-----END PGP PUBLIC KEY BLOCK-----" ); diff --git a/libretroshare/src/retroshare/rsids.h b/libretroshare/src/retroshare/rsids.h index a284de11c..22f35f8f9 100644 --- a/libretroshare/src/retroshare/rsids.h +++ b/libretroshare/src/retroshare/rsids.h @@ -163,8 +163,9 @@ template t int n=0; if(s.length() != ID_SIZE_IN_BYTES*2) { - if(!s.empty()) - std::cerr << "t_RsGenericIdType<>::t_RsGenericIdType(std::string&): supplied string in constructor has wrong size." << std::endl; + if(!s.empty()) + std::cerr << "t_RsGenericIdType<>::t_RsGenericIdType(std::string&): supplied string in constructor has wrong size. Expected ID size=" << ID_SIZE_IN_BYTES << " String=\"" << s << "\"" << std::endl; + clear(); return; } @@ -184,8 +185,8 @@ template t else if(b >= '0' && b <= '9') bytes[i] += (b-'0') << 4*(1-k) ; else { - std::cerr << "t_RsGenericIdType<>::t_RsGenericIdType(std::string&): supplied string is not purely hexadecimal" << std::endl; - clear(); + std::cerr << "t_RsGenericIdType<>::t_RsGenericIdType(std::string&): supplied string is not purely hexadecimal: s=\"" << s << "\"" << std::endl; + clear(); return; } } diff --git a/retroshare-gui/src/gui/RetroShareLink.cpp b/retroshare-gui/src/gui/RetroShareLink.cpp index 4da365b33..af9f64f15 100644 --- a/retroshare-gui/src/gui/RetroShareLink.cpp +++ b/retroshare-gui/src/gui/RetroShareLink.cpp @@ -281,7 +281,9 @@ void RetroShareLink::fromUrl(const QUrl& url) _type = TYPE_CERTIFICATE; _radix = urlQuery.queryItemValue(CERTIFICATE_RADIX); - std::cerr << "Got a certificate link!!" << std::endl; +#ifdef DEBUG_RSLINK + std::cerr << "Got a certificate link!!" << std::endl; +#endif check() ; return; }