diff options
author | Bram Moolenaar <Bram@vim.org> | 2011-03-26 13:56:48 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2011-03-26 13:56:48 +0100 |
commit | 21377c8d5ff60a94c76e5fb3b32f462cc2880290 (patch) | |
tree | f5f464d126c9498544dabd33b7f83fb848735964 | |
parent | b3c5284c5b228794bd17f63bb5fa8d78e5d22ecd (diff) | |
download | vim-git-7.3.144.tar.gz |
updated for version 7.3.144v7.3.144
Problem: Crash with ":python help(dir)". (Kearn Holliday)
Solution: Fix the way the type is set on objects. (Tobias Columbus)
-rw-r--r-- | src/if_python.c | 14 | ||||
-rw-r--r-- | src/version.c | 2 |
2 files changed, 9 insertions, 7 deletions
diff --git a/src/if_python.c b/src/if_python.c index 26e5f1d88..fc493ecaa 100644 --- a/src/if_python.c +++ b/src/if_python.c @@ -780,7 +780,7 @@ OutputSetattr(PyObject *self, char *name, PyObject *val) PythonIO_Init(void) { /* Fixups... */ - OutputType.ob_type = &PyType_Type; + PyType_Ready(&OutputType); return PythonIO_Init_io(); } @@ -1402,12 +1402,12 @@ PythonMod_Init(void) static char *(argv[2]) = {"/must>not&exist/foo", NULL}; /* Fixups... */ - BufferType.ob_type = &PyType_Type; - RangeType.ob_type = &PyType_Type; - WindowType.ob_type = &PyType_Type; - BufListType.ob_type = &PyType_Type; - WinListType.ob_type = &PyType_Type; - CurrentType.ob_type = &PyType_Type; + PyType_Ready(&BufferType); + PyType_Ready(&RangeType); + PyType_Ready(&WindowType); + PyType_Ready(&BufListType); + PyType_Ready(&WinListType); + PyType_Ready(&CurrentType); /* Set sys.argv[] to avoid a crash in warn(). */ PySys_SetArgv(1, argv); diff --git a/src/version.c b/src/version.c index bec8769dc..212df7aa6 100644 --- a/src/version.c +++ b/src/version.c @@ -715,6 +715,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 144, +/**/ 143, /**/ 142, |