|
|
|
|
|
|
|
|
|
|
xen-devel
Re: [Xen-devel] [PATCH]: xl: don't segfault parsing disk configs, suppor
Gianni Tedesco writes ("[Xen-devel] [PATCH]: xl: don't segfault parsing disk
configs, support NULL physpath and ioemu:"):
> Switch to a state machine parser since it's easier to handle all these
> exotic cases without segfaulting. NULL physpaths are now allowed and a
> dodgy hack is introduced to skip over the "ioemu:" prefix for a
> virtpath. Also fixes a leak of buf2.
I'm not convinced that it is clearer. It's certainly a lot longer:
132 lines added for 50 removed.
Perhaps we should just import a regexp parser and use that ? Really,
we should have a regexp or some other kind of declarative statement of
the syntax.
Possible regexp parsers include pcre and flex. flex has the advantage
that we're using it already so it's just another line in the
Makefile.
Ian.
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
|
|
|
|