Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorWillian Padovani Germano <wpgermano@gmail.com>2003-08-11 03:18:00 +0400
committerWillian Padovani Germano <wpgermano@gmail.com>2003-08-11 03:18:00 +0400
commit2289f3abb60c4dc66cfe6008f80f7bfc6783f906 (patch)
treeb20ac76a785dc44a334c8af91b1bb4245c8adee9 /source
parent3295b394b62027eca378b58053b9b65366673ab6 (diff)
Exppython:
- Adding argv to the builtin sys Python module: Currently only argv[0] is there. This fixes a weird error that can make correct scripts fail.
Diffstat (limited to 'source')
-rw-r--r--source/blender/python/BPY_interface.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/python/BPY_interface.c b/source/blender/python/BPY_interface.c
index 9b4e47a6236..722f7934462 100644
--- a/source/blender/python/BPY_interface.c
+++ b/source/blender/python/BPY_interface.c
@@ -190,6 +190,8 @@ void init_syspath(void)
if (mod) {
d = PyModule_GetDict(mod); /* borrowed ref */
PyDict_SetItemString(d, "executable", Py_BuildValue("s", bprogname));
+ /* in the future this can be extended to have more argv's if needed: */
+ PyDict_SetItemString(d, "argv", Py_BuildValue("[s]", bprogname));
Py_DECREF(mod);
}
}