1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-22 02:46:38 +02:00

Fixed crash when loading ruby script if file does not exist, with Ruby >= 1.9 only (bug #18064)

This commit is contained in:
Sebastien Helleu
2006-10-20 09:19:51 +00:00
parent 06c4cf4144
commit a3878a522c
10 changed files with 66 additions and 22 deletions
+3 -4
View File
@@ -1592,14 +1592,13 @@ weechat_python_load (t_weechat_plugin *plugin, char *filename)
if ((fp = fopen (filename, "r")) == NULL)
{
plugin->print_server (plugin,
"Python error: unable to open file \"%s\"",
plugin->print_server (plugin, "Python error: script \"%s\" not found",
filename);
return 0;
}
python_current_script = NULL;
/* PyEval_AcquireLock (); */
python_current_interpreter = Py_NewInterpreter ();
PySys_SetArgv(1, argv);