This service will be undergoing maintenance at 00:00 UTC, 2016-08-01. It is expected to last about 1 hours

Bug 237039

Summary: libvirt.rng contains invalid regular expressions
Product: [Fedora] Fedora Reporter: Robin Green <greenrd>
Component: libvirtAssignee: Daniel Veillard <veillard>
Status: CLOSED UPSTREAM QA Contact:
Severity: low Docs Contact:
Priority: medium    
Version: rawhideKeywords: Patch
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-04-19 03:57:20 EDT Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Attachments:
Description Flags
fix none

Description Robin Green 2007-04-18 20:16:22 EDT
Description of problem:
I tried to use trang to convert libvirt.rng to an XML schema file, but it failed
with errors about four of the regular expressions.

Version-Release number of selected component (if applicable):
libvirt-0.2.1-2.fc7

How reproducible:
Always

Steps to Reproduce:
1. /usr/lib/jvm/java-sun/bin/java -jar /usr/local/trang-20030619/trang.jar
/usr/share/doc/libvirt-0.2.1/libvirt.rng ~/libvirt.xsd
  
Actual results:
/usr/share/doc/libvirt-0.2.1/libvirt.rng:711:29: error: invalid parameter:
invalid regular expression: illegal escape
/usr/share/doc/libvirt-0.2.1/libvirt.rng:716:29: error: invalid parameter:
invalid regular expression: illegal escape
/usr/share/doc/libvirt-0.2.1/libvirt.rng:721:29: error: invalid parameter:
invalid regular expression: illegal escape
/usr/share/doc/libvirt-0.2.1/libvirt.rng:726:29: error: invalid parameter:
invalid regular expression: illegal escape

Expected results:
conversion successful

Additional info:
I had to use sun Java (I used 1.5) to run trang because gij crashed with a NPE
when I tried it.
Comment 1 Robin Green 2007-04-18 20:24:06 EDT
Created attachment 152971 [details]
fix
Comment 2 Daniel Veillard 2007-04-19 03:57:20 EDT
Hum, it seems my regexp parser in libxml2 is a bit laxist
  http://www.w3.org/TR/xmlschema-2/#dt-cces1

I'm trying to fix this in libxml2, in the meantime I applied the patch, thanks.
Note however that the rng is lagging behind, it was not updated while elements
and constructs have been added in the code, which seriously reduces its
usefulness.
Maybe when libvirt developments slows down a bit it will be easier to 
resynchronize (any way I take patches ! I tried to keep the rng readable and
commented)

  thanks,

Daniel