2016-04-15 0:10 GMT+03:00 Bram Moolenaar <[email protected]>:
>
> Patch 7.4.1743
> Problem: Clang warns for uninitialzed variable. (Michael Jarvis)
> Solution: Initialize it.
> Files: src/if_py_both.h
>
>
> *** ../vim-7.4.1742/src/if_py_both.h 2016-04-14 17:40:52.668464428 +0200
> --- src/if_py_both.h 2016-04-14 23:06:20.007064066 +0200
> ***************
> *** 6070,6076 ****
> ConvertFromPySequence(PyObject *obj, typval_T *tv)
> {
> PyObject *lookup_dict;
> ! int ret;
>
> if (!(lookup_dict = PyDict_New()))
> return -1;
> --- 6070,6076 ----
> ConvertFromPySequence(PyObject *obj, typval_T *tv)
> {
> PyObject *lookup_dict;
> ! int ret = 0;
Actually I have a memory leak here. Correct patch is
diff -r 641c0377d059 src/if_py_both.h
--- a/src/if_py_both.h Thu Apr 07 01:55:55 2016 +0300
+++ b/src/if_py_both.h Fri Apr 15 03:58:42 2016 +0300
@@ -6081,9 +6081,10 @@
tv->v_type = VAR_LIST;
tv->vval.v_list = (((ListObject *)(obj))->list);
++tv->vval.v_list->lv_refcount;
+ ret = 0;
}
else if (PyIter_Check(obj) || PySequence_Check(obj))
- return convert_dl(obj, tv, pyseq_to_tv, lookup_dict);
+ ret = convert_dl(obj, tv, pyseq_to_tv, lookup_dict);
else
{
PyErr_FORMAT(PyExc_TypeError,
>
> if (!(lookup_dict = PyDict_New()))
> return -1;
> *** ../vim-7.4.1742/src/version.c 2016-04-14 22:54:20.818618214 +0200
> --- src/version.c 2016-04-14 23:08:16.433842797 +0200
> ***************
> *** 750,751 ****
> --- 750,753 ----
> { /* Add new patch number below this line */
> + /**/
> + 1743,
> /**/
>
> --
> Facepalm statement #7: "Last week I almost got pregnant!"
>
> /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
> /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
> \\\ an exciting new programming language -- http://www.Zimbu.org ///
> \\\ help me help AIDS victims -- http://ICCF-Holland.org ///
>
> --
> --
> 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
>
> ---
> You received this message because you are subscribed to the Google Groups
> "vim_dev" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
--
--
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
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.