r23773 - gnucash/trunk/src/python - Python bindings: open init file in read mode, not read-write
Geert Janssens
gjanssens at code.gnucash.org
Sun Jan 26 06:47:12 EST 2014
Author: gjanssens
Date: 2014-01-26 06:47:11 -0500 (Sun, 26 Jan 2014)
New Revision: 23773
Trac: http://svn.gnucash.org/trac/changeset/23773
Modified:
gnucash/trunk/src/python/gncmod-python.c
Log:
Python bindings: open init file in read mode, not read-write
Modified: gnucash/trunk/src/python/gncmod-python.c
===================================================================
--- gnucash/trunk/src/python/gncmod-python.c 2014-01-26 00:27:44 UTC (rev 23772)
+++ gnucash/trunk/src/python/gncmod-python.c 2014-01-26 11:47:11 UTC (rev 23773)
@@ -79,7 +79,7 @@
pkgdatadir = gnc_path_get_pkgdatadir();
init_filename = g_build_filename(pkgdatadir, "python/init.py", (char*)NULL);
g_debug("Looking for python init script at %s", (init_filename ? init_filename : "<null>"));
- fp = fopen(init_filename, "r+");
+ fp = fopen(init_filename, "r");
if (fp)
{
PyRun_SimpleFile(fp, init_filename);
More information about the gnucash-changes
mailing list