Patch 7.3.656
Problem:    Internal error in :pyeval.
Solution:   Handle failed object conversion. (ZyX)
Files:      src/if_python.c, src/if_python3.c


*** ../vim-7.3.655/src/if_python.c      2012-06-30 13:34:29.000000000 +0200
--- src/if_python.c     2012-09-05 18:52:50.000000000 +0200
***************
*** 1025,1032 ****
  
  static PySequenceMethods BufferAsSeq = {
      (PyInquiry)               BufferLength,       /* sq_length,    len(x)   */
!     (binaryfunc)      0, /* BufferConcat, */       /* sq_concat,    x+y      
*/
!     (PyIntArgFunc)    0, /* BufferRepeat, */       /* sq_repeat,    x*n      
*/
      (PyIntArgFunc)    BufferItem,         /* sq_item,      x[i]     */
      (PyIntIntArgFunc) BufferSlice,        /* sq_slice,     x[i:j]   */
      (PyIntObjArgProc) BufferAssItem,      /* sq_ass_item,  x[i]=v   */
--- 1025,1032 ----
  
  static PySequenceMethods BufferAsSeq = {
      (PyInquiry)               BufferLength,       /* sq_length,    len(x)   */
!     (binaryfunc)      0,                  /* BufferConcat, sq_concat, x+y */
!     (PyIntArgFunc)    0,                  /* BufferRepeat, sq_repeat, x*n */
      (PyIntArgFunc)    BufferItem,         /* sq_item,      x[i]     */
      (PyIntIntArgFunc) BufferSlice,        /* sq_slice,     x[i:j]   */
      (PyIntObjArgProc) BufferAssItem,      /* sq_ass_item,  x[i]=v   */
***************
*** 1787,1792 ****
--- 1787,1796 ----
        case VAR_DICT: ++rettv->vval.v_dict->dv_refcount; break;
        case VAR_LIST: ++rettv->vval.v_list->lv_refcount; break;
        case VAR_FUNC: func_ref(rettv->vval.v_string);    break;
+       case VAR_UNKNOWN:
+           rettv->v_type = VAR_NUMBER;
+           rettv->vval.v_number = 0;
+           break;
      }
  }
  
*** ../vim-7.3.655/src/if_python3.c     2012-06-29 16:28:23.000000000 +0200
--- src/if_python3.c    2012-09-05 18:52:50.000000000 +0200
***************
*** 1817,1822 ****
--- 1817,1826 ----
        case VAR_DICT: ++rettv->vval.v_dict->dv_refcount; break;
        case VAR_LIST: ++rettv->vval.v_list->lv_refcount; break;
        case VAR_FUNC: func_ref(rettv->vval.v_string);    break;
+       case VAR_UNKNOWN:
+           rettv->v_type = VAR_NUMBER;
+           rettv->vval.v_number = 0;
+           break;
      }
  }
  
*** ../vim-7.3.655/src/version.c        2012-09-05 18:48:22.000000000 +0200
--- src/version.c       2012-09-05 18:53:20.000000000 +0200
***************
*** 721,722 ****
--- 721,724 ----
  {   /* Add new patch number below this line */
+ /**/
+     656,
  /**/

-- 
DEAD PERSON:  I'm getting better!
CUSTOMER:     No, you're not -- you'll be stone dead in a moment.
MORTICIAN:    Oh, I can't take him like that -- it's against regulations.
                                  The Quest for the Holy Grail (Monty Python)

 /// 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

Raspunde prin e-mail lui