astepano / rpms / vim

Forked from rpms/vim 6 years ago
Clone
fe46cb6
To: vim_dev@googlegroups.com
fe46cb6
Subject: Patch 7.3.929
fe46cb6
Fcc: outbox
fe46cb6
From: Bram Moolenaar <Bram@moolenaar.net>
fe46cb6
Mime-Version: 1.0
fe46cb6
Content-Type: text/plain; charset=UTF-8
fe46cb6
Content-Transfer-Encoding: 8bit
fe46cb6
------------
fe46cb6
fe46cb6
Patch 7.3.929 (after 7.3.924)
fe46cb6
Problem:    Compiler warning for unused variable. Not freeing unused string.
fe46cb6
Solution:   Remove the variable. Clear the options.
fe46cb6
Files:      src/option.c
fe46cb6
fe46cb6
fe46cb6
*** ../vim-7.3.928/src/option.c	2013-05-06 03:52:44.000000000 +0200
fe46cb6
--- src/option.c	2013-05-06 06:42:03.000000000 +0200
fe46cb6
***************
fe46cb6
*** 9705,9713 ****
fe46cb6
  {
fe46cb6
      struct vimoption *p;
fe46cb6
      int		opt_idx;
fe46cb6
! 
fe46cb6
!     buf_T *buf = (buf_T *) from;
fe46cb6
!     win_T *win = (win_T *) from;
fe46cb6
  
fe46cb6
      opt_idx = findoption(name);
fe46cb6
      p = &(options[opt_idx]);
fe46cb6
--- 9705,9711 ----
fe46cb6
  {
fe46cb6
      struct vimoption *p;
fe46cb6
      int		opt_idx;
fe46cb6
!     buf_T	*buf = (buf_T *)from;
fe46cb6
  
fe46cb6
      opt_idx = findoption(name);
fe46cb6
      p = &(options[opt_idx]);
fe46cb6
***************
fe46cb6
*** 9716,9775 ****
fe46cb6
      {
fe46cb6
  	/* global option with local value: use local value if it's been set */
fe46cb6
  	case PV_EP:
fe46cb6
! 	    *buf->b_p_ep = NUL;
fe46cb6
  	    break;
fe46cb6
  	case PV_KP:
fe46cb6
! 	    *buf->b_p_kp = NUL;
fe46cb6
  	    break;
fe46cb6
  	case PV_PATH:
fe46cb6
! 	    *buf->b_p_path = NUL;
fe46cb6
  	    break;
fe46cb6
  	case PV_AR:
fe46cb6
  	    buf->b_p_ar = -1;
fe46cb6
  	    break;
fe46cb6
  	case PV_TAGS:
fe46cb6
! 	    *buf->b_p_tags = NUL;
fe46cb6
  	    break;
fe46cb6
  #ifdef FEAT_FIND_ID
fe46cb6
  	case PV_DEF:
fe46cb6
! 	    *buf->b_p_def = NUL;
fe46cb6
  	    break;
fe46cb6
  	case PV_INC:
fe46cb6
! 	    *buf->b_p_inc = NUL;
fe46cb6
  	    break;
fe46cb6
  #endif
fe46cb6
  #ifdef FEAT_INS_EXPAND
fe46cb6
  	case PV_DICT:
fe46cb6
! 	    *buf->b_p_dict = NUL;
fe46cb6
  	    break;
fe46cb6
  	case PV_TSR:
fe46cb6
! 	    *buf->b_p_tsr = NUL;
fe46cb6
  	    break;
fe46cb6
  #endif
fe46cb6
  #ifdef FEAT_QUICKFIX
fe46cb6
  	case PV_EFM:
fe46cb6
! 	    *buf->b_p_efm = NUL;
fe46cb6
  	    break;
fe46cb6
  	case PV_GP:
fe46cb6
! 	    *buf->b_p_gp = NUL;
fe46cb6
  	    break;
fe46cb6
  	case PV_MP:
fe46cb6
! 	    *buf->b_p_mp = NUL;
fe46cb6
  	    break;
fe46cb6
  #endif
fe46cb6
  #if defined(FEAT_BEVAL) && defined(FEAT_EVAL)
fe46cb6
  	case PV_BEXPR:
fe46cb6
! 	    *buf->b_p_bexpr = NUL;
fe46cb6
  	    break;
fe46cb6
  #endif
fe46cb6
  #if defined(FEAT_CRYPT)
fe46cb6
  	case PV_CM:
fe46cb6
! 	    *buf->b_p_cm = NUL;
fe46cb6
  	    break;
fe46cb6
  #endif
fe46cb6
  #ifdef FEAT_STL_OPT
fe46cb6
  	case PV_STL:
fe46cb6
! 	    *win->w_p_stl = NUL;
fe46cb6
  	    break;
fe46cb6
  #endif
fe46cb6
      }
fe46cb6
--- 9714,9773 ----
fe46cb6
      {
fe46cb6
  	/* global option with local value: use local value if it's been set */
fe46cb6
  	case PV_EP:
fe46cb6
! 	    clear_string_option(&buf->b_p_ep);
fe46cb6
  	    break;
fe46cb6
  	case PV_KP:
fe46cb6
! 	    clear_string_option(&buf->b_p_kp);
fe46cb6
  	    break;
fe46cb6
  	case PV_PATH:
fe46cb6
! 	    clear_string_option(&buf->b_p_path);
fe46cb6
  	    break;
fe46cb6
  	case PV_AR:
fe46cb6
  	    buf->b_p_ar = -1;
fe46cb6
  	    break;
fe46cb6
  	case PV_TAGS:
fe46cb6
! 	    clear_string_option(&buf->b_p_tags);
fe46cb6
  	    break;
fe46cb6
  #ifdef FEAT_FIND_ID
fe46cb6
  	case PV_DEF:
fe46cb6
! 	    clear_string_option(&buf->b_p_def);
fe46cb6
  	    break;
fe46cb6
  	case PV_INC:
fe46cb6
! 	    clear_string_option(&buf->b_p_inc);
fe46cb6
  	    break;
fe46cb6
  #endif
fe46cb6
  #ifdef FEAT_INS_EXPAND
fe46cb6
  	case PV_DICT:
fe46cb6
! 	    clear_string_option(&buf->b_p_dict);
fe46cb6
  	    break;
fe46cb6
  	case PV_TSR:
fe46cb6
! 	    clear_string_option(&buf->b_p_tsr);
fe46cb6
  	    break;
fe46cb6
  #endif
fe46cb6
  #ifdef FEAT_QUICKFIX
fe46cb6
  	case PV_EFM:
fe46cb6
! 	    clear_string_option(&buf->b_p_efm);
fe46cb6
  	    break;
fe46cb6
  	case PV_GP:
fe46cb6
! 	    clear_string_option(&buf->b_p_gp);
fe46cb6
  	    break;
fe46cb6
  	case PV_MP:
fe46cb6
! 	    clear_string_option(&buf->b_p_mp);
fe46cb6
  	    break;
fe46cb6
  #endif
fe46cb6
  #if defined(FEAT_BEVAL) && defined(FEAT_EVAL)
fe46cb6
  	case PV_BEXPR:
fe46cb6
! 	    clear_string_option(&buf->b_p_bexpr);
fe46cb6
  	    break;
fe46cb6
  #endif
fe46cb6
  #if defined(FEAT_CRYPT)
fe46cb6
  	case PV_CM:
fe46cb6
! 	    clear_string_option(&buf->b_p_cm);
fe46cb6
  	    break;
fe46cb6
  #endif
fe46cb6
  #ifdef FEAT_STL_OPT
fe46cb6
  	case PV_STL:
fe46cb6
! 	    clear_string_option(&((win_T *)from)->w_p_stl);
fe46cb6
  	    break;
fe46cb6
  #endif
fe46cb6
      }
fe46cb6
*** ../vim-7.3.928/src/version.c	2013-05-06 06:26:10.000000000 +0200
fe46cb6
--- src/version.c	2013-05-06 06:35:06.000000000 +0200
fe46cb6
***************
fe46cb6
*** 730,731 ****
fe46cb6
--- 730,733 ----
fe46cb6
  {   /* Add new patch number below this line */
fe46cb6
+ /**/
fe46cb6
+     929,
fe46cb6
  /**/
fe46cb6
fe46cb6
-- 
fe46cb6
Microsoft: "Windows NT 4.0 now has the same user-interface as Windows 95"
fe46cb6
    Windows 95: "Press CTRL-ALT-DEL to reboot"
fe46cb6
Windows NT 4.0: "Press CTRL-ALT-DEL to login"
fe46cb6
fe46cb6
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
fe46cb6
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
fe46cb6
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
fe46cb6
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///