by wlach · 15y ago · 0 comments
http://live.gnome.org/dconf#Design
I'm generally a fan of text-based configuration files but in this case I think the benefit exceeds the cost. Reading configuration used to take a non-trivial amount of time on startup.
Best of both worlds: rapid parsing / memory management (really, does it matter that much), while preserving human management.
Oh yeah: and the textual version is definitive.
One way out would be to compile the text-based config files into the config blob and rebuild the blob if the text-based config files change.
I can't quite figure out an attack vector, but I always have a bad feeling when I trust a binary blob and load it into memory without any parsing.
The middle ground would be to cache settings in a binary file.