source: pkg/kev/main/xchat/trunk/debian/patches/46_CVE-2009-0315.dpatch @ 5760

Revision 5760, 913 bytes checked in by alanbach-guest, 4 years ago (diff)
  • Added xchat to Kev
Line 
1#! /bin/sh /usr/share/dpatch/dpatch-run
2## 46_CVE-2009-0315.dpatch by Nico Golde <nion@debian.org>
3##
4## All lines beginning with `## DP:' are a description of the patch.
5## DP: No description.
6
7@DPATCH@
8diff -urNad xchat-2.8.6~/plugins/python/python.c xchat-2.8.6/plugins/python/python.c
9--- xchat-2.8.6~/plugins/python/python.c        2008-03-29 06:57:35.000000000 +0100
10+++ xchat-2.8.6/plugins/python/python.c 2009-02-05 19:13:02.000000000 +0100
11@@ -1106,6 +1106,7 @@
12        }
13 
14        PySys_SetArgv(1, argv);
15+       PyRun_SimpleString("import sys; sys.path = filter(None, sys.path)");
16        PySys_SetObject("__plugin__", (PyObject *) plugin);
17 
18        /* Set stdout and stderr to xchatout. */
19@@ -2110,6 +2111,7 @@
20        Py_SetProgramName("xchat");
21        Py_Initialize();
22        PySys_SetArgv(1, argv);
23+       PyRun_SimpleString("import sys; sys.path = filter(None, sys.path)");
24 
25        Plugin_Type.ob_type = &PyType_Type;
26        Context_Type.ob_type = &PyType_Type;
Note: See TracBrowser for help on using the repository browser.