On Tuesday 05 April 2005 6:34 pm, Derek Atkins wrote: > Unfortunately it's not trivial, because the API between the UI and the > non-UI bits don't pass enough information to notice the error.
Could we check the return value of the fprintf in line 931 (and elsewhere) in src/backend/file/io-gncxml-v2.c and set a QofBackendError ? (using qof_book_get_backend?) xmlElemDump is a void prototype: http://www.xmlsoft.org/html/libxml-tree.html#xmlElemDump but in each case in io-gnc-xml-v2.c, it is followed by an fprintf. It wouldn't be particularly specific, but it would indicate that the write functions failed - for whatever reason. In QSF, I use xmlDocFormatDump which does return a negative value on error - although I'm not utilising that at the moment. http://www.xmlsoft.org/html/libxml-tree.html#xmlDocFormatDump I can check for a negative return int and set the same QofBackendError - added to qofbackend.h and an appropriate message in src/app-file/gnc-file.c - would that solve the bug? -- Neil Williams ============= http://www.dcglug.org.uk/ http://www.nosoftwarepatents.com/ http://sourceforge.net/projects/isbnsearch/ http://www.neil.williamsleesmill.me.uk/ http://www.biglumber.com/x/web?qs=0x8801094A28BCB3E3
pgpY9thPfAcWh.pgp
Description: PGP signature
_______________________________________________ gnucash-devel mailing list [email protected] https://lists.gnucash.org/mailman/listinfo/gnucash-devel
