Peter O'Gorman's file i/o patches.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@6646 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
Dave Peticolas 2002-01-24 06:34:49 +00:00
parent 243babdc03
commit 19cadf17da
4 changed files with 19 additions and 2 deletions

View File

@ -155,6 +155,7 @@ Stefan Nobis <stefan-ml@snobis.de> German translation patch
Martin Norbäck <d95mback@dtek.chalmers.se> Swedish translation
Peter Norton <spacey@inch.com> for a valiant attempt at a GTK port
Bill Nottingham <notting@redhat.com> guile configure patch
Peter O'Gorman <peter@pogma.com> file i/o patches
OmNiBuS <webmaster@obsidian.uia.net> web site graphics & content
Gordon Oliver <gordo@pincoya.com> multiple currency status line patch
Alan Orndorff <dwarf@solarisresources.com> Solaris packager

View File

@ -825,6 +825,13 @@ Nielsen</glossterm>
</glossdef>
</glossentry>
<glossentry>
<glossterm><email>peter@pogma.com</email> Peter O'Gorman</glossterm>
<glossdef>
<para>file i/o patches</para>
</glossdef>
</glossentry>
<glossentry>
<glossterm><email>webmaster@obsidian.uia.net</email> OmNiBuS
</glossterm>

View File

@ -361,6 +361,10 @@ gnc_write_example_account(GncExampleAccount *gea, const gchar *filename)
FILE *out;
out = fopen(filename, "w");
if (out == NULL)
{
return FALSE;
}
fprintf(out, "<?xml version=\"1.0\"?>\n");
fprintf(out, "<" GNC_ACCOUNT_STRING ">\n");

View File

@ -950,15 +950,20 @@ gnc_book_write_to_xml_file_v2(GNCBook *book, const char *filename)
FILE *out;
out = fopen(filename, "w");
if (out == NULL)
{
return FALSE;
}
gnc_book_write_to_xml_filehandle_v2 (book, out);
write_emacs_trailer(out);
if(fclose(out) != 0)
if (fclose(out) != 0)
{
return FALSE;
}
return TRUE;
}