mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Python bindings: open init file in read mode, not read-write
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23773 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
66290779a1
commit
b5435e7631
@ -79,7 +79,7 @@ libgncmod_python_gnc_module_init(int refcount)
|
||||
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);
|
||||
|
Loading…
Reference in New Issue
Block a user