Patch 8.1.0661

2018-12-29 Fir de Conversatie Bram Moolenaar


Patch 8.1.0661
Problem:Clipboard regexp might be used recursively.
Solution:   Check for recursive use and bail out.
Files:  src/regexp.c, src/proto/regexp.pro, src/os_unix.c


*** ../vim-8.1.0660/src/regexp.c2018-12-21 16:04:16.324437435 +0100
--- src/regexp.c2018-12-29 22:24:58.276693199 +0100
***
*** 8210,8215 
--- 8210,8224 
  #endif
  
  /*
+  * Return whether "prog" is currently being executed.
+  */
+ int
+ regprog_in_use(regprog_T *prog)
+ {
+ return prog->re_in_use;
+ }
+ 
+ /*
   * Match a regexp against a string.
   * "rmp->regprog" is a compiled regexp as returned by vim_regcomp().
   * Note: "rmp->regprog" may be freed and changed.
*** ../vim-8.1.0660/src/proto/regexp.pro2018-05-17 13:52:49.0 
+0200
--- src/proto/regexp.pro2018-12-29 22:25:02.584654266 +0100
***
*** 13,18 
--- 13,19 
  list_T *reg_submatch_list(int no);
  regprog_T *vim_regcomp(char_u *expr_arg, int re_flags);
  void vim_regfree(regprog_T *prog);
+ int regprog_in_use(regprog_T *prog);
  int vim_regexec_prog(regprog_T **prog, int ignore_case, char_u *line, colnr_T 
col);
  int vim_regexec(regmatch_T *rmp, char_u *line, colnr_T col);
  int vim_regexec_nl(regmatch_T *rmp, char_u *line, colnr_T col);
*** ../vim-8.1.0660/src/os_unix.c   2018-12-29 13:09:43.242347695 +0100
--- src/os_unix.c   2018-12-29 22:22:20.674036581 +0100
***
*** 1688,1696 
  if (x_no_connect)
return FALSE;
  
! /* Check for a match with "exclude:" from 'clipboard'. */
  if (clip_exclude_prog != NULL)
  {
if (vim_regexec_prog(_exclude_prog, FALSE, T_NAME, (colnr_T)0))
return FALSE;
  }
--- 1688,1702 
  if (x_no_connect)
return FALSE;
  
! // Check for a match with "exclude:" from 'clipboard'.
  if (clip_exclude_prog != NULL)
  {
+   // Just in case we get called recursively, return FALSE.  This could
+   // happen if vpeekc() is used while executing the prog and it causes a
+   // related callback to be invoked.
+   if (regprog_in_use(clip_exclude_prog))
+   return FALSE;
+ 
if (vim_regexec_prog(_exclude_prog, FALSE, T_NAME, (colnr_T)0))
return FALSE;
  }
*** ../vim-8.1.0660/src/version.c   2018-12-29 21:00:20.953498877 +0100
--- src/version.c   2018-12-29 22:27:56.171107925 +0100
***
*** 801,802 
--- 801,804 
  {   /* Add new patch number below this line */
+ /**/
+ 661,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
82. AT names you Customer of the Month for the third consecutive time.

 /// Bram Moolenaar -- b...@moolenaar.net -- 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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Patch 8.1.0660

2018-12-29 Fir de Conversatie Bram Moolenaar


Patch 8.1.0660
Problem:sign_unplace() may leak memory.
Solution:   Free the group name before returning.  Add a few more tests.
(Yegappan Lakshmanan)
Files:  src/evalfunc.c, src/testdir/test_signs.vim


*** ../vim-8.1.0659/src/evalfunc.c  2018-12-29 18:53:07.843607433 +0100
--- src/evalfunc.c  2018-12-29 20:42:30.370357956 +0100
***
*** 11578,11584 
if (argvars[1].v_type != VAR_DICT)
{
EMSG(_(e_dictreq));
!   return;
}
dict = argvars[1].vval.v_dict;
  
--- 11578,11584 
if (argvars[1].v_type != VAR_DICT)
{
EMSG(_(e_dictreq));
!   goto cleanup;
}
dict = argvars[1].vval.v_dict;
  
***
*** 11589,11595 
{
EMSG2(_("E158: Invalid buffer name: %s"),
tv_get_string(>di_tv));
!   return;
}
}
if (dict_find(dict, (char_u *)"id", -1) != NULL)
--- 11589,11595 
{
EMSG2(_("E158: Invalid buffer name: %s"),
tv_get_string(>di_tv));
!   goto cleanup;
}
}
if (dict_find(dict, (char_u *)"id", -1) != NULL)
***
*** 11608,11613 
--- 11608,11615 
if (sign_unplace(sign_id, group, buf, 0) == OK)
rettv->vval.v_number = 0;
  }
+ 
+ cleanup:
  vim_free(group);
  }
  #endif
*** ../vim-8.1.0659/src/testdir/test_signs.vim  2018-12-29 18:53:07.843607433 
+0100
--- src/testdir/test_signs.vim  2018-12-29 20:48:20.911472019 +0100
***
*** 385,390 
--- 385,392 
  \ {"lnum" : -1})', 'E885:')
call assert_fails('call sign_place(22, "", "sign1", "Xsign",
  \ {"lnum" : 0})', 'E885:')
+   call assert_fails('call sign_place(22, "", "sign1", "Xsign",
+ \ {"lnum" : []})', 'E745:')
call assert_equal(-1, sign_place(1, "*", "sign1", "Xsign", {"lnum" : 10}))
  
" Tests for sign_getplaced()
***
*** 420,428 
  \ {'id' : 20, 'buffer' : 'buffer.c'})", 'E158:')
call assert_fails("call sign_unplace('',
  \ {'id' : 20, 'buffer' : ''})", 'E158:')
!   call assert_fails("call sign_unplace('',
  \ {'id' : 20, 'buffer' : 200})", 'E158:')
!   call assert_fails("call sign_unplace('', 'mySign')", 'E715:')
  
" Tests for sign_undefine()
call assert_equal(0, sign_undefine("sign1"))
--- 422,430 
  \ {'id' : 20, 'buffer' : 'buffer.c'})", 'E158:')
call assert_fails("call sign_unplace('',
  \ {'id' : 20, 'buffer' : ''})", 'E158:')
!   call assert_fails("call sign_unplace('g1',
  \ {'id' : 20, 'buffer' : 200})", 'E158:')
!   call assert_fails("call sign_unplace('g1', 'mySign')", 'E715:')
  
" Tests for sign_undefine()
call assert_equal(0, sign_undefine("sign1"))
***
*** 664,670 
call delete("Xsign")
call sign_unplace('*')
call sign_undefine()
!   enew  | only
  endfunc
  
  " Place signs used for ":sign unplace" command test
--- 666,672 
call delete("Xsign")
call sign_unplace('*')
call sign_undefine()
!   enew | only
  endfunc
  
  " Place signs used for ":sign unplace" command test
***
*** 1013,1019 
  
call sign_unplace('*')
call sign_undefine()
!   enew  | only
call delete("Xsign1")
call delete("Xsign2")
  endfunc
--- 1015,1021 
  
call sign_unplace('*')
call sign_undefine()
!   enew | only
call delete("Xsign1")
call delete("Xsign2")
  endfunc
***
*** 1042,1047 
--- 1044,1052 
  
call assert_equal(1, sign_place(0, 'g1', 'sign1', 'Xsign',
  \ {'lnum' : 11}))
+   " Check for the next generated sign id in this group
+   call assert_equal(2, sign_place(0, 'g1', 'sign1', 'Xsign',
+ \ {'lnum' : 12}))
call assert_equal(0, sign_unplace('g1', {'id' : 1}))
call assert_equal(10,
  \ sign_getplaced('Xsign', {'id' : 1})[0].signs[0].lnum)
***
*** 1049,1055 
call delete("Xsign")
call sign_unplace('*')
call sign_undefine()
!   enew  | only
  endfunc
  
  " Test for sign priority
--- 1054,1060 
call delete("Xsign")
call sign_unplace('*')
call sign_undefine()
!   enew | only
  endfunc
  
  " Test for sign priority
***
*** 1085,1090 
--- 1090,1097 
" Error case
call assert_fails("call sign_place(1, 'g1', 'sign1', 'Xsign',
  \ [])", 'E715:')
+   call assert_fails("call sign_place(1, 'g1', 'sign1', 'Xsign',
+ \ {'priority' : []})", 'E745:')
call sign_unplace('*')
  
" Tests for the :sign place command with priority
***
*** 1104,1110 
  
call sign_unplace('*')
call sign_undefine()
!   enew  | only
call delete("Xsign")
  endfunc
  
--- ,1117 
  
call sign_unplace('*')

Patch 8.1.0659

2018-12-29 Fir de Conversatie Bram Moolenaar


Patch 8.1.0659 (after 8.1.0658)
Problem:Build failure without the sign feature.
Solution:   Put the sign struct declarations outside of the #ifdef.
Files:  src/structs.h


*** ../vim-8.1.0658/src/structs.h   2018-12-27 00:28:27.501299292 +0100
--- src/structs.h   2018-12-29 20:00:42.683438234 +0100
***
*** 731,738 
  #define PT_FLAG_INS_START_INCL1   // insert at start included in 
property
  #define PT_FLAG_INS_END_INCL  2   // insert at end included in property
  
- 
- #if defined(FEAT_SIGNS) || defined(PROTO)
  // Sign group
  typedef struct signgroup_S
  {
--- 731,736 
***
*** 741,750 
  char_usg_name[1]; // sign group name
  } signgroup_T;
  
- // Macros to get the sign group structure from the group name
- #define SGN_KEY_OFF   offsetof(signgroup_T, sg_name)
- #define HI2SG(hi) ((signgroup_T *)((hi)->hi_key - SGN_KEY_OFF))
- 
  typedef struct signlist signlist_T;
  
  struct signlist
--- 739,744 
***
*** 758,763 
--- 752,762 
  signlist_T  *prev;/* previous entry -- for easy 
reordering */
  };
  
+ #if defined(FEAT_SIGNS) || defined(PROTO)
+ // Macros to get the sign group structure from the group name
+ #define SGN_KEY_OFF   offsetof(signgroup_T, sg_name)
+ #define HI2SG(hi) ((signgroup_T *)((hi)->hi_key - SGN_KEY_OFF))
+ 
  // Default sign priority for highlighting
  #define SIGN_DEF_PRIO 10
  
*** ../vim-8.1.0658/src/version.c   2018-12-29 18:53:07.847607399 +0100
--- src/version.c   2018-12-29 20:03:12.542203100 +0100
***
*** 801,802 
--- 801,804 
  {   /* Add new patch number below this line */
+ /**/
+ 659,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
78. You find yourself dialing IP numbers on the phone.

 /// Bram Moolenaar -- b...@moolenaar.net -- 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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.1.0658

2018-12-29 Fir de Conversatie Bram Moolenaar


Yegappan wrote:

> On Sat, Dec 29, 2018 at 10:09 AM Tony Mechelynck
>  wrote:
> >
> > On Sat, Dec 29, 2018 at 6:55 PM Bram Moolenaar  wrote:
> > >
> > >
> > > Patch 8.1.0658
> > > Problem:Deleting signs and completion for :sign is insufficient.
> > > Solution:   Add deleting signs in a specified or any group from the 
> > > current
> > > cursor location.  Add group and priority to sign command
> > > completion. Add tests for different sign unplace commands. 
> > > Update
> > > help text.  Add tests for sign jump with group. Update help 
> > > for
> > > sign jump. (Yegappan Lakshmanan, closes #3731)
> > > Files:  runtime/doc/sign.txt, src/buffer.c, src/evalfunc.c, 
> > > src/ex_cmds.c,
> > > src/netbeans.c, src/proto/buffer.pro, src/proto/ex_cmds.pro,
> > > src/testdir/test_signs.vim
> >
> > After applying this patch, I get the following compile error in the
> > Small and Tiny featuresets. I suspect dome #ifdef directives are
> > missing.
> >
> 
> Yes. The changes to the buffer.pro file removed the check for FEAT_SIGNS.
> You can use the attached patch.

These files are automatically generated, you cannot use #ifdef there.
We can move the struct declarations outside of the #ifdef.

-- 
hundred-and-one symptoms of being an internet addict:
77. The phone company asks you to test drive their new PBX system

 /// Bram Moolenaar -- b...@moolenaar.net -- 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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.1.0658

2018-12-29 Fir de Conversatie Yegappan Lakshmanan
Hi,

On Sat, Dec 29, 2018 at 10:09 AM Tony Mechelynck
 wrote:
>
> On Sat, Dec 29, 2018 at 6:55 PM Bram Moolenaar  wrote:
> >
> >
> > Patch 8.1.0658
> > Problem:Deleting signs and completion for :sign is insufficient.
> > Solution:   Add deleting signs in a specified or any group from the current
> > cursor location.  Add group and priority to sign command
> > completion. Add tests for different sign unplace commands. 
> > Update
> > help text.  Add tests for sign jump with group. Update help for
> > sign jump. (Yegappan Lakshmanan, closes #3731)
> > Files:  runtime/doc/sign.txt, src/buffer.c, src/evalfunc.c, 
> > src/ex_cmds.c,
> > src/netbeans.c, src/proto/buffer.pro, src/proto/ex_cmds.pro,
> > src/testdir/test_signs.vim
>
> After applying this patch, I get the following compile error in the
> Small and Tiny featuresets. I suspect dome #ifdef directives are
> missing.
>

Yes. The changes to the buffer.pro file removed the check for FEAT_SIGNS.
You can use the attached patch.

Regards,
Yegappan

> linux-2iyu:~/.build/vim/vim-hg/src/shadow-tiny # (make || echo 'exit
> status' $? ; date) 2>&1 |tee -a make.log
> gcc -c -I. -Iproto -DHAVE_CONFIG_H -O2 -fno-strength-reduce -Wall
> -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1-o objects/buffer.o
> buffer.c
> In file included from proto.h:65:0,
>  from vim.h:2121,
>  from buffer.c:28:
> proto/buffer.pro:74:19: error: unknown type name ‘signlist_T’; did you
> mean ‘list_T’?
>  int sign_in_group(signlist_T *sign, char_u *group);
>^~
>list_T
> proto/buffer.pro:75:23: error: unknown type name ‘signlist_T’; did you
> mean ‘list_T’?
>  dict_T *sign_get_info(signlist_T *sign);
>^~
>list_T
> proto/buffer.pro:81:1: error: unknown type name ‘signlist_T’; did you
> mean ‘list_T’?
>  signlist_T *buf_getsign_with_id(buf_T *buf, int id, char_u *group);
>  ^~
>  list_T
> make: *** [Makefile:2952: objects/buffer.o] Error 1
> exit status 2
> Sat 29 Dec 19:01:24 CET 2018
>

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


sign_tiny_build.diff
Description: Binary data


Re: Patch 8.1.0658

2018-12-29 Fir de Conversatie Tony Mechelynck
On Sat, Dec 29, 2018 at 6:55 PM Bram Moolenaar  wrote:
>
>
> Patch 8.1.0658
> Problem:Deleting signs and completion for :sign is insufficient.
> Solution:   Add deleting signs in a specified or any group from the current
> cursor location.  Add group and priority to sign command
> completion. Add tests for different sign unplace commands. Update
> help text.  Add tests for sign jump with group. Update help for
> sign jump. (Yegappan Lakshmanan, closes #3731)
> Files:  runtime/doc/sign.txt, src/buffer.c, src/evalfunc.c, src/ex_cmds.c,
> src/netbeans.c, src/proto/buffer.pro, src/proto/ex_cmds.pro,
> src/testdir/test_signs.vim

After applying this patch, I get the following compile error in the
Small and Tiny featuresets. I suspect dome #ifdef directives are
missing.

linux-2iyu:~/.build/vim/vim-hg/src/shadow-tiny # (make || echo 'exit
status' $? ; date) 2>&1 |tee -a make.log
gcc -c -I. -Iproto -DHAVE_CONFIG_H -O2 -fno-strength-reduce -Wall
-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1-o objects/buffer.o
buffer.c
In file included from proto.h:65:0,
 from vim.h:2121,
 from buffer.c:28:
proto/buffer.pro:74:19: error: unknown type name ‘signlist_T’; did you
mean ‘list_T’?
 int sign_in_group(signlist_T *sign, char_u *group);
   ^~
   list_T
proto/buffer.pro:75:23: error: unknown type name ‘signlist_T’; did you
mean ‘list_T’?
 dict_T *sign_get_info(signlist_T *sign);
   ^~
   list_T
proto/buffer.pro:81:1: error: unknown type name ‘signlist_T’; did you
mean ‘list_T’?
 signlist_T *buf_getsign_with_id(buf_T *buf, int id, char_u *group);
 ^~
 list_T
make: *** [Makefile:2952: objects/buffer.o] Error 1
exit status 2
Sat 29 Dec 19:01:24 CET 2018


Best regards,
Tony.

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Patch 8.1.0658

2018-12-29 Fir de Conversatie Bram Moolenaar


Patch 8.1.0658
Problem:Deleting signs and completion for :sign is insufficient.
Solution:   Add deleting signs in a specified or any group from the current
cursor location.  Add group and priority to sign command
completion. Add tests for different sign unplace commands. Update
help text.  Add tests for sign jump with group. Update help for
sign jump. (Yegappan Lakshmanan, closes #3731)
Files:  runtime/doc/sign.txt, src/buffer.c, src/evalfunc.c, src/ex_cmds.c,
src/netbeans.c, src/proto/buffer.pro, src/proto/ex_cmds.pro,
src/testdir/test_signs.vim


*** ../vim-8.1.0657/runtime/doc/sign.txt2018-12-21 15:16:57.475579814 
+0100
--- runtime/doc/sign.txt2018-12-29 18:36:00.268781805 +0100
***
*** 251,263 
all the files it appears in.
  
  :sign unplace *
!   Remove all placed signs in the global group.
  
  :sign unplace * group=*
!   Remove all placed signs in all the groups.
  
  :sign unplace
!   Remove the placed sign at the cursor position.
  
  
  LISTING PLACED SIGNS  *:sign-place-list*
--- 251,274 
all the files it appears in.
  
  :sign unplace *
!   Remove placed signs in the global group from all the files.
! 
! :sign unplace * group={group}
!   Remove placed signs in group {group} from all the files.
  
  :sign unplace * group=*
!   Remove placed signs in all the groups from all the files.
  
  :sign unplace
!   Remove a placed sign at the cursor position. If multiple signs
!   are placed in the line, then only one is removed.
! 
! :sign unplace group={group}
!   Remove a placed sign in group {group} at the cursor
!   position.
! 
! :sign unplace group=*
!   Remove a placed sign in any group at the cursor position.
  
  
  LISTING PLACED SIGNS  *:sign-place-list*
***
*** 271,286 
  :sign place group={group} file={fname}
List signs in group {group} placed in file {fname}.
  
  :sign place buffer={nr}
List signs placed in buffer {nr}.
  
  :sign place group={group} buffer={nr}
List signs in group {group} placed in buffer {nr}.
  
! :sign place   List placed signs in all files.
  
  :sign place group={group}
!   List placed signs in all sign groups in all the files.
  
  
  JUMPING TO A SIGN *:sign-jump* *E157*
--- 282,306 
  :sign place group={group} file={fname}
List signs in group {group} placed in file {fname}.
  
+ :sign place group=* file={fname}
+   List signs in all the groups placed in file {fname}.
+ 
  :sign place buffer={nr}
List signs placed in buffer {nr}.
  
  :sign place group={group} buffer={nr}
List signs in group {group} placed in buffer {nr}.
  
! :sign place group=* buffer={nr}
!   List signs in all the groups placed in buffer {nr}.
! 
! :sign place   List placed signs in the global group in all files.
  
  :sign place group={group}
!   List placed signs with sign group {group} in all files.
! 
! :sign place group=*
!   List placed signs in all sign groups in all files.
  
  
  JUMPING TO A SIGN *:sign-jump* *E157*
***
*** 292,300 
--- 312,326 
If the file isn't displayed in window and the current file can
not be |abandon|ed this fails.
  
+ :sign jump {id} group={group} file={fname}
+   Same but jump to the sign in group {group}
+ 
  :sign jump {id} buffer={nr}   *E934*
Same, but use buffer {nr}.  This fails if buffer {nr} does not
have a name.
  
+ :sign jump {id} group={group} buffer={nr}
+   Same but jump to the sign in group {group}
+ 
  
   vim:tw=78:ts=8:noet:ft=help:norl:
*** ../vim-8.1.0657/src/buffer.c2018-12-27 00:28:27.497299324 +0100
--- src/buffer.c2018-12-29 18:38:43.291325605 +0100
***
*** 6077,6086 
  int
  sign_in_group(signlist_T *sign, char_u *group)
  {
! return ((group != NULL && STRCMP(group, "*") == 0) ||
!   (group == NULL && sign->group == NULL) ||
!   (group != NULL && sign->group != NULL &&
!   STRCMP(group, sign->group->sg_name) == 0));
  }
  
  /*
--- 6077,6086 
  int
  sign_in_group(signlist_T *sign, char_u *group)
  {
! return ((group != NULL && STRCMP(group, "*") == 0)
!   || (group == NULL && sign->group == NULL)
!   || (group != NULL && sign->group != NULL
!&& STRCMP(group, sign->group->sg_name) == 0));
  }
  
  /*
***
*** 6207,6212 
--- 6207,6213 
  linenr_T
  

Re: Patch 8.1.0656

2018-12-29 Fir de Conversatie Elimar Riesebieter
* Elimar Riesebieter  [2018-12-29 12:35 +0100]:

> * Bram Moolenaar  [2018-12-29 11:04 +0100]:
> 
> > 
> > Patch 8.1.0656
> > Problem:Trying to reconnect to X server may cause problems.
> > Solution:   Do no try reconnecting when exiting. (James McCoy)
> > Files:  src/os_unix.c
> 
> Building in a tmux window stalls at:
> 
> VIMRUNTIME=../../runtime; export VIMRUNTIME;  ../vim -f  -u unix.vim -U NONE 
> --noplugin --not-a-term -s dotest.in test64.in --cmd 'au SwapExists * let 
> v:swapchoice = "e"' > /dev/null
> 
> Didn't found any buildprocess. Had to kill window, though.
> 
> 8.1.0655 builds fine.

8.1.0657 tests running successful. Build runs fine and vim seems to
work properly so far.

Thanks
Elimar
-- 
  Do you smell something burning or is it me?

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.1.0656

2018-12-29 Fir de Conversatie Bram Moolenaar


I wrote:

> Dominique wrote:
> 
> > Bram Moolenaar wrote:
> > 
> > > Patch 8.1.0656
> > > Problem:Trying to reconnect to X server may cause problems.
> > > Solution:   Do no try reconnecting when exiting. (James McCoy)
> > > Files:  src/os_unix.c
> > 
> > Something is wrong with this patch. I get several of these errors
> > "E956: Cannot use pattern recursively" whenever I press a key,
> > which makes vim unusable. I have to "kill -9" the vim process to
> > quit it. Going back to vim-8.1.655, everything is fine.
> > It happens even with "vim --clean" or "vim -u NONE".
> 
> Strange, I don't see any problems.  Can you back out parts of the patch
> to see what change is causing trouble?

Must be the regexp that is used to check for the "exclude" item in
'clipboard'.  Let's just check for v_dying and exiting directly.

-- 
Proof techniques #2: Proof by Oddity.
SAMPLE: To prove that horses have an infinite number of legs.
(1) Horses have an even number of legs.
(2) They have two legs in back and fore legs in front.
(3) This makes a total of six legs, which certainly is an odd number of
legs for a horse.
(4) But the only number that is both odd and even is infinity.
(5) Therefore, horses must have an infinite number of legs.

 /// Bram Moolenaar -- b...@moolenaar.net -- 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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Patch 8.1.0657

2018-12-29 Fir de Conversatie Bram Moolenaar


Patch 8.1.0657 (after 8.1.0656)
Problem:Get error for using regexp recursively. (Dominique Pelle)
Solution:   Do no check if connection is desired.
Files:  src/os_unix.c


*** ../vim-8.1.0656/src/os_unix.c   2018-12-29 11:03:19.158409090 +0100
--- src/os_unix.c   2018-12-29 13:07:34.475428967 +0100
***
*** 1742,1749 
  static void
  may_restore_clipboard(void)
  {
! // Only try restoring if we want the connection.
! if (x_connect_to_server() && xterm_dpy_retry_count > 0)
  {
--xterm_dpy_retry_count;
  
--- 1742,1749 
  static void
  may_restore_clipboard(void)
  {
! // No point in restoring the connecting if we are exiting or dying.
! if (!exiting && !v_dying && xterm_dpy_retry_count > 0)
  {
--xterm_dpy_retry_count;
  
*** ../vim-8.1.0656/src/version.c   2018-12-29 11:03:19.158409090 +0100
--- src/version.c   2018-12-29 13:09:23.998509304 +0100
***
*** 801,802 
--- 801,804 
  {   /* Add new patch number below this line */
+ /**/
+ 657,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
74. Your most erotic dreams are about cybersex

 /// Bram Moolenaar -- b...@moolenaar.net -- 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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.1.0656

2018-12-29 Fir de Conversatie Bram Moolenaar


Dominique wrote:

> Bram Moolenaar wrote:
> 
> > Patch 8.1.0656
> > Problem:Trying to reconnect to X server may cause problems.
> > Solution:   Do no try reconnecting when exiting. (James McCoy)
> > Files:  src/os_unix.c
> 
> Something is wrong with this patch. I get several of these errors
> "E956: Cannot use pattern recursively" whenever I press a key,
> which makes vim unusable. I have to "kill -9" the vim process to
> quit it. Going back to vim-8.1.655, everything is fine.
> It happens even with "vim --clean" or "vim -u NONE".

Strange, I don't see any problems.  Can you back out parts of the patch
to see what change is causing trouble?

-- 
hundred-and-one symptoms of being an internet addict:
73. You give your dog used motherboards instead of bones

 /// Bram Moolenaar -- b...@moolenaar.net -- 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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.1.0656

2018-12-29 Fir de Conversatie Dominique Pellé
Bram Moolenaar wrote:

> Patch 8.1.0656
> Problem:Trying to reconnect to X server may cause problems.
> Solution:   Do no try reconnecting when exiting. (James McCoy)
> Files:  src/os_unix.c

Something is wrong with this patch. I get several of these errors
"E956: Cannot use pattern recursively" whenever I press a key,
which makes vim unusable. I have to "kill -9" the vim process to
quit it. Going back to vim-8.1.655, everything is fine.
It happens even with "vim --clean" or "vim -u NONE".

$ ./vim --version
VIM - Vi IMproved 8.1 (2018 May 18, compiled Dec 29 2018 12:19:12)
Included patches: 1-656
Compiled by pel@pel-laptop
Huge version without GUI.  Features included (+) or not (-):
+acl   +extra_search  +mouse_netterm +tag_old_static
+arabic+farsi +mouse_sgr -tag_any_white
+autocmd   +file_in_path  -mouse_sysmouse-tcl
+autochdir +find_in_path  +mouse_urxvt   +termguicolors
-autoservername+float +mouse_xterm   +terminal
-balloon_eval  +folding   +multi_byte+terminfo
+balloon_eval_term -footer+multi_lang+termresponse
-browse+fork()-mzscheme  +textobjects
++builtin_terms+gettext   +netbeans_intg +textprop
+byte_offset   -hangul_input  +num64 +timers
+channel   +iconv +packages  +title
+cindent   +insert_expand +path_extra-toolbar
+clientserver  +job   -perl  +user_commands
+clipboard +jumplist  +persistent_undo   +vartabs
+cmdline_compl +keymap+postscript+vertsplit
+cmdline_hist  +lambda+printer   +virtualedit
+cmdline_info  +langmap   +profile   +visual
+comments  +libcall   +python/dyn+visualextra
+conceal   +linebreak +python3/dyn   +viminfo
+cryptv+lispindent+quickfix  +vreplace
+cscope+listcmds  +reltime   +wildignore
+cursorbind+localmap  +rightleft +wildmenu
+cursorshape   -lua   -ruby  +windows
+dialog_con+menu  +scrollbind+writebackup
+diff  +mksession +signs +X11
+digraphs  +modify_fname  +smartindent   +xfontset
-dnd   +mouse +startuptime   -xim
-ebcdic-mouseshape+statusline+xpm
+emacs_tags+mouse_dec -sun_workshop  +xsmp_interact
+eval  +mouse_gpm +syntax+xterm_clipboard
+ex_extra  -mouse_jsbterm +tag_binary-xterm_save
   system vimrc file: "$VIM/vimrc"
 user vimrc file: "$HOME/.vimrc"
 2nd user vimrc file: "~/.vim/vimrc"
  user exrc file: "$HOME/.exrc"
   defaults file: "$VIMRUNTIME/defaults.vim"
  fall-back for $VIM: "/usr/local/share/vim"
Compilation: gcc -c -I. -Iproto -DHAVE_CONFIG_H -g -O2
-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1
Linking: gcc   -L/usr/local/lib -Wl,--as-needed -o vim-lSM -lICE
-lXpm -lXt -lX11 -lXdmcp -lSM -lICE  -lm -ltinfo -lnsl  -lselinux
-lacl -lattr -lgpm -ldl

I'm using xubuntu-16.04. I can try to debug tonight.

Dominique

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.1.0656

2018-12-29 Fir de Conversatie Elimar Riesebieter
* Bram Moolenaar  [2018-12-29 11:04 +0100]:

> 
> Patch 8.1.0656
> Problem:Trying to reconnect to X server may cause problems.
> Solution:   Do no try reconnecting when exiting. (James McCoy)
> Files:src/os_unix.c

Building in a tmux window stalls at:

VIMRUNTIME=../../runtime; export VIMRUNTIME;  ../vim -f  -u unix.vim -U NONE 
--noplugin --not-a-term -s dotest.in test64.in --cmd 'au SwapExists * let 
v:swapchoice = "e"' > /dev/null

Didn't found any buildprocess. Had to kill window, though.

8.1.0655 builds fine.

Elimar
-- 
  The path to source is always uphill!
-unknown-

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Patch 8.1.0656

2018-12-29 Fir de Conversatie Bram Moolenaar


Patch 8.1.0656
Problem:Trying to reconnect to X server may cause problems.
Solution:   Do no try reconnecting when exiting. (James McCoy)
Files:  src/os_unix.c


*** ../vim-8.1.0655/src/os_unix.c   2018-12-28 17:01:55.307292166 +0100
--- src/os_unix.c   2018-12-29 10:55:01.706850859 +0100
***
*** 1671,1676 
--- 1671,1702 
  return 0;
  }
  
+ /*
+  * Return TRUE when connection to the X server is desired.
+  */
+ static int
+ x_connect_to_server(void)
+ {
+ // No point in connecting if we are exiting or dying.
+ if (exiting || v_dying)
+   return FALSE;
+ 
+ #if defined(FEAT_CLIENTSERVER)
+ if (x_force_connect)
+   return TRUE;
+ #endif
+ if (x_no_connect)
+   return FALSE;
+ 
+ /* Check for a match with "exclude:" from 'clipboard'. */
+ if (clip_exclude_prog != NULL)
+ {
+   if (vim_regexec_prog(_exclude_prog, FALSE, T_NAME, (colnr_T)0))
+   return FALSE;
+ }
+ return TRUE;
+ }
+ 
  #if defined(FEAT_X11) && defined(FEAT_XCLIPBOARD)
  # if defined(HAVE_SETJMP_H)
  /*
***
*** 1716,1722 
  static void
  may_restore_clipboard(void)
  {
! if (xterm_dpy_retry_count > 0)
  {
--xterm_dpy_retry_count;
  
--- 1742,1749 
  static void
  may_restore_clipboard(void)
  {
! // Only try restoring if we want the connection.
! if (x_connect_to_server() && xterm_dpy_retry_count > 0)
  {
--xterm_dpy_retry_count;
  
***
*** 1737,1764 
  #endif
  
  /*
-  * Return TRUE when connection to the X server is desired.
-  */
- static int
- x_connect_to_server(void)
- {
- #if defined(FEAT_CLIENTSERVER)
- if (x_force_connect)
-   return TRUE;
- #endif
- if (x_no_connect)
-   return FALSE;
- 
- /* Check for a match with "exclude:" from 'clipboard'. */
- if (clip_exclude_prog != NULL)
- {
-   if (vim_regexec_prog(_exclude_prog, FALSE, T_NAME, (colnr_T)0))
-   return FALSE;
- }
- return TRUE;
- }
- 
- /*
   * Test if "dpy" and x11_window are valid by getting the window title.
   * I don't actually want it yet, so there may be a simpler call to use, but
   * this will cause the error handler x_error_check() to be called if anything
--- 1764,1769 
*** ../vim-8.1.0655/src/version.c   2018-12-28 23:22:36.270750732 +0100
--- src/version.c   2018-12-29 10:59:48.804432411 +0100
***
*** 801,802 
--- 801,804 
  {   /* Add new patch number below this line */
+ /**/
+ 656,
  /**/

-- 
"Thou shalt not follow the Null Pointer, for at its end Chaos and
Madness lie."

 /// Bram Moolenaar -- b...@moolenaar.net -- 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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.