To: vim_dev@googlegroups.com Subject: Patch 8.0.0539 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.0.0539 (after 8.0.0538) Problem: Startup test fails on Mac. Solution: Use another term name, "unknown" is known. Avoid a 2 second delay. Files: src/testdir/test_startup.vim, src/main.c, src/proto/main.pro, src/term.c *** ../vim-8.0.0538/src/testdir/test_startup.vim 2017-04-02 16:54:05.820018573 +0200 --- src/testdir/test_startup.vim 2017-04-02 17:14:53.108377770 +0200 *************** *** 216,222 **** endif let save_term = $TERM ! let $TERM = 'unknown' let out = system(GetVimCommand() . ' -c''set term'' -c cq') call assert_match("defaulting to 'ansi'", out) let $TERM = save_term --- 216,222 ---- endif let save_term = $TERM ! let $TERM = 'unknownxxx' let out = system(GetVimCommand() . ' -c''set term'' -c cq') call assert_match("defaulting to 'ansi'", out) let $TERM = save_term *** ../vim-8.0.0538/src/main.c 2017-03-19 21:47:46.897119250 +0100 --- src/main.c 2017-04-02 17:19:31.626671792 +0200 *************** *** 1013,1018 **** --- 1013,1027 ---- } /* + * Return TRUE when the --not-a-term argument was found. + */ + int + is_not_a_term() + { + return params.not_a_term; + } + + /* * Main loop: Execute Normal mode commands until exiting Vim. * Also used to handle commands in the command-line window, until the window * is closed. *** ../vim-8.0.0538/src/proto/main.pro 2017-03-18 18:10:08.767696888 +0100 --- src/proto/main.pro 2017-04-02 17:19:34.310655332 +0200 *************** *** 1,6 **** --- 1,7 ---- /* main.c */ int vim_main2(void); void common_init(mparm_T *paramp); + int is_not_a_term(void); void main_loop(int cmdwin, int noexmode); void getout_preserve_modified(int exitval); void getout(int exitval); *** ../vim-8.0.0538/src/term.c 2017-03-16 17:23:26.839815753 +0100 --- src/term.c 2017-04-02 17:19:51.842547812 +0200 *************** *** 1705,1711 **** { screen_start(); /* don't know where cursor is now */ out_flush(); ! ui_delay(2000L, TRUE); } set_string_option_direct((char_u *)"term", -1, term, OPT_FREE, 0); --- 1705,1712 ---- { screen_start(); /* don't know where cursor is now */ out_flush(); ! if (!is_not_a_term()) ! ui_delay(2000L, TRUE); } set_string_option_direct((char_u *)"term", -1, term, OPT_FREE, 0); *** ../vim-8.0.0538/src/version.c 2017-04-02 16:54:05.820018573 +0200 --- src/version.c 2017-04-02 17:20:27.574328630 +0200 *************** *** 766,767 **** --- 766,769 ---- { /* Add new patch number below this line */ + /**/ + 539, /**/ -- hundred-and-one symptoms of being an internet addict: 258. When you want to see your girlfriend, you surf to her homepage. /// Bram Moolenaar -- Bram@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 ///