xml-commons-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From n..@apache.org
Subject svn commit: r350239 - /xml/commons/trunk/java/src/org/apache/xml/resolver/apps/XParseError.java
Date Thu, 01 Dec 2005 12:34:30 GMT
Author: ndw
Date: Thu Dec  1 04:34:26 2005
New Revision: 350239

URL: http://svn.apache.org/viewcvs?rev=350239&view=rev
Log:
Make sure the first warning and/or error is displayed

Modified:
    xml/commons/trunk/java/src/org/apache/xml/resolver/apps/XParseError.java

Modified: xml/commons/trunk/java/src/org/apache/xml/resolver/apps/XParseError.java
URL: http://svn.apache.org/viewcvs/xml/commons/trunk/java/src/org/apache/xml/resolver/apps/XParseError.java?rev=350239&r1=350238&r2=350239&view=diff
==============================================================================
--- xml/commons/trunk/java/src/org/apache/xml/resolver/apps/XParseError.java (original)
+++ xml/commons/trunk/java/src/org/apache/xml/resolver/apps/XParseError.java Thu Dec  1 04:34:26
2005
@@ -101,32 +101,26 @@
 
   /** SAX2 API */
   public void error(SAXParseException exception) {
-    if (showErrors) {
-      if (errorCount+warningCount < maxMessages) {
+    errorCount++;
+    if (showErrors && (errorCount+warningCount < maxMessages)) {
 	message("Error", exception);
-      }
-      errorCount++;
     }
   }
 
   /** SAX2 API */
   public void fatalError(SAXParseException exception) {
-    if (showErrors) {
-      if (errorCount+warningCount < maxMessages) {
+    errorCount++;
+    fatalCount++;
+    if (showErrors && (errorCount+warningCount < maxMessages)) {
 	message("Fatal error", exception);
-      }
-      errorCount++;
-      fatalCount++;
     }
   }
 
   /** SAX2 API */
   public void warning(SAXParseException exception) {
-    if (showWarnings) {
-      if ((errorCount+warningCount < maxMessages)) {
+    warningCount++;
+    if (showWarnings && (errorCount+warningCount < maxMessages)) {
 	message("Warning", exception);
-      }
-      warningCount++;
     }
   }
 



Mime
View raw message