On Tue, Jun 12, 2012 at 7:02 AM, Piotr Skamruk <piotr.skam...@gmail.com> wrote:
> On Saturday, April 14, 2012 4:36:29 PM UTC+2, Christian Brabandt wrote:
>> Hi Thomas!
>> [...]
>> diff --git a/src/if_py_both.h b/src/if_py_both.h
>> --- a/src/if_py_both.h
>> +++ b/src/if_py_both.h
>> @@ -74,7 +74,7 @@
>>      char *str = NULL;
>>      int error = ((OutputObject *)(self))->error;
>>
>> -    if (!PyArg_ParseTuple(args, "et#", ENC_OPT, &str, &len))
>> +    if (!PyArg_ParseTuple(args, "et#", ENC_OPT, &str, &len) || str == NUL)
>>         return NULL;
>>
>>      Py_BEGIN_ALLOW_THREADS
>
> Thanx for this patch.
> This works for me both on ubuntu and on debian, and now vim stopped to crash 
> with sigsegv.
>

Just an fyi, it is still broken with this patch. It only prevents the
segfault, and doesn't fix the underlying bug.
e.g. :python print 'hi' doesn't segfault anymore, but it also doesn't
print anything which.

The only way I know on how to fix this (not segfault and print) is to
take out -O2 from the CFLAGS.

Cheers

-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

Reply via email to