1. Shlomi Fish
  2. perl-XML-LibXML

Commits

pa...@9ae0c189-cd1f-4510-a509-f4891f5cf20d  committed 4f04c32

minor bugfix in RelaxNG validation code introduced while adding structured errors support

  • Participants
  • Parent commits 57eb8c1
  • Branches structerror

Comments (0)

Files changed (1)

File LibXML.xs

View file
         xmlRelaxNGFreeValidCtxt( vctxt );
 
         LibXML_report_error(saved_error, 0);
-        if (RETVAL>1) {
-	  /* not valid, although libxml2 gave no reason */
-          croak( "validation failed for unknown reason\n" );
-          XSRETURN_UNDEF;
+        if ( RETVAL > 0 ) {
+	    /* not valid, although libxml2 gave no reason */
+            croak( "validation failed for unknown reason\n" );
+            XSRETURN_UNDEF;
         }
         if ( RETVAL == -1 ) {
             croak( "API Error" );
 
         LibXML_report_error(saved_error, 0);
         if ( RETVAL > 0 ) {
+	    /* not valid, although libxml2 gave no reason */
             croak( "validation failed for unknown reason\n" );
             XSRETURN_UNDEF;
         }