r23598 - gnucash/trunk/src/backend/xml - Bug 710824 - GnuCash should sanitise UTF-8 before serialising files
John Ralls
jralls at ceridwen.us
Mon Dec 23 16:12:54 EST 2013
On Dec 23, 2013, at 12:44 PM, Derek Atkins <warlord at MIT.EDU> wrote:
> John Ralls <jralls at code.gnucash.org> writes:
>
>> Author: jralls
>> Date: 2013-12-22 17:32:04 -0500 (Sun, 22 Dec 2013)
>> New Revision: 23598
>> Trac: http://svn.gnucash.org/trac/changeset/23598
>>
>> Added:
>> gnucash/trunk/src/backend/xml/gnc-xml-helper.c
>> Modified:
>> gnucash/trunk/src/backend/xml/Makefile.am
>> gnucash/trunk/src/backend/xml/gnc-recurrence-xml-v2.c
>> gnucash/trunk/src/backend/xml/gnc-schedxaction-xml-v2.c
>> gnucash/trunk/src/backend/xml/gnc-transaction-xml-v2.c
>> gnucash/trunk/src/backend/xml/gnc-xml-helper.h
>> gnucash/trunk/src/backend/xml/io-gncxml-v2.c
>> gnucash/trunk/src/backend/xml/sixtp-dom-generators.c
>> gnucash/trunk/src/backend/xml/sixtp-to-dom-parser.c
>> gnucash/trunk/src/backend/xml/test/Makefile.am
>> gnucash/trunk/src/backend/xml/test/test-string-converters.c
>> Log:
>> Bug 710824 - GnuCash should sanitise UTF-8 before serialising files
>>
>> to avoid writing broken unparseable XML.
>> This checks for both bad UTF8 and for invalid control characters
>> that libxml2 doesn't convert to entities.
>
> Are we going to need a similar process for the SQL backend?
>
I don’t think so. SQL won’t refuse to load a database because one field has a character that doesn’t match some spec. In fact, it doesn’t much care what you put into it; as far as the DB is concerned, bytes is bytes.
Regards,
John Ralls
More information about the gnucash-devel
mailing list