diff src/org/tmatesoft/hg/repo/HgRemoteRepository.java @ 207:1bf0a5af2d5d

Conditional debug printouts
author Artem Tikhomirov <tikhomirov.artem@gmail.com>
date Thu, 28 Apr 2011 03:10:56 +0200
parents 66fd2c73c56f
children 6a2481866491
line wrap: on
line diff
--- a/src/org/tmatesoft/hg/repo/HgRemoteRepository.java	Thu Apr 28 02:47:44 2011 +0200
+++ b/src/org/tmatesoft/hg/repo/HgRemoteRepository.java	Thu Apr 28 03:10:56 2011 +0200
@@ -77,10 +77,14 @@
 				sslContext = SSLContext.getInstance("SSL");
 				class TrustEveryone implements X509TrustManager {
 					public void checkClientTrusted(X509Certificate[] chain, String authType) throws CertificateException {
-						System.out.println("checkClientTrusted " + authType);
+						if (debug) {
+							System.out.println("checkClientTrusted:" + authType);
+						}
 					}
 					public void checkServerTrusted(X509Certificate[] chain, String authType) throws CertificateException {
-						System.out.println("checkServerTrusted" + authType);
+						if (debug) {
+							System.out.println("checkServerTrusted:" + authType);
+						}
 					}
 					public X509Certificate[] getAcceptedIssuers() {
 						return new X509Certificate[0];