solaris /dev/console patch
Havoc Pennington
hp at redhat.com
Thu Apr 27 11:38:14 PDT 2006
John (J5) Palmieri wrote:
>
> The biggest problem with the XML parser is the validation which is one
> big fragile logic statement. Every time an option is added one must go
> into that statement and figure out where to add the || FOO_OPTION's or
> && FOO_OPTION's and where one must completely restructure the logic. At
> least that is what I remember when writing the at_console patch. Using
> a DTD and validating parser would have been better but I don't even
> think we actually work with libxml anymore and on Red Hat/Fedora at we
> have move moved d-bus into /bin and /lib which would mean libxml would
> have to be moved to /lib (expat is right now) in order to switch.
>
Eh, I don't really believe that would be better anyway; it'd just be
less obviously complicated (largely because a bunch of validation would
get punted or missed), not necessarily less complicated. DTDs are in my
experience extremely hard to write correctly, and few people (including
me) really understand them. Custom validation code usually has better
error messages, too.
Not to say that DTDs are useless just that I don't really see them as a
substitute for sanity-check code in a lot of cases.
Havoc
More information about the dbus
mailing list