commits@javamail.java.net

[mercurial:95] Disable some debug error messages that are "expected" to avoid confusing

From: <shannon_at_kenai.com>
Date: Thu, 4 Dec 2008 01:10:16 +0000 (GMT)

Repository: mercurial
Revision: 95
Author: Bill Shannon <bill.shannon_at_sun.com>
Date: 2008-12-04 01:05:34 UTC

Log Message:
-----------
Disable some debug error messages that are "expected" to avoid
confusing users.

Modified Paths:
--------------
    mail/src/main/java/javax/mail/Session.java

Diffs:
-----
diff -r 9fa975389faa -r 7d457a491607
mail/src/main/java/javax/mail/Session.java
--- a/mail/src/main/java/javax/mail/Session.java Wed Nov 19
12:14:59 2008 -0800
+++ b/mail/src/main/java/javax/mail/Session.java Wed Dec 03
17:05:34 2008 -0800
@@ -1,7 +1,7 @@
 /*
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
  *
- * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 1997-2008 Sun Microsystems, Inc. All rights reserved.
  *
  * The contents of this file are subject to the terms of either the
GNU
  * General Public License Version 2 only ("GPL") or the Common
Development
@@ -1061,6 +1061,8 @@
            loader.load(clis);
            if (debug)
                pr("DEBUG: successfully loaded file: " + name);
+ } catch (FileNotFoundException fex) {
+ // ignore it
        } catch (IOException e) {
            if (debug) {
                pr("DEBUG: not loading file: " + name);
@@ -1091,8 +1093,10 @@
                if (debug)
                    pr("DEBUG: successfully loaded resource: " + name);
            } else {
+ /*
                if (debug)
                    pr("DEBUG: not loading resource: " + name);
+ */
            }
        } catch (IOException e) {
            if (debug)
@@ -1142,6 +1146,8 @@
                            if (debug)
                                pr("DEBUG: not loading resource: " +
url);
                        }
+ } catch (FileNotFoundException fex) {
+ // ignore it
                    } catch (IOException ioex) {
                        if (debug)
                            pr("DEBUG: " + ioex);
@@ -1163,8 +1169,10 @@
 
        // if failed to load anything, fall back to old technique, just
in case
        if (!anyLoaded) {
+ /*
            if (debug)
                pr("DEBUG: !anyLoaded");
+ */
            loadResource("/" + name, cl, loader);
        }
     }