mirror of
https://github.com/vim/vim.git
synced 2025-07-26 11:04:33 -04:00
patch 8.0.1061: Coverity: no check for NULL command
Problem: Coverity: no check for NULL command. Solution: Check for NULL list item.
This commit is contained in:
parent
3971905bac
commit
6756c7037f
@ -38,7 +38,9 @@
|
|||||||
* in tl_scrollback are no longer used.
|
* in tl_scrollback are no longer used.
|
||||||
*
|
*
|
||||||
* TODO:
|
* TODO:
|
||||||
* - ":term NONE" does not work in MS-Windows.
|
* - ":term NONE" does not work on MS-Windows.
|
||||||
|
* https://github.com/vim/vim/pull/2056
|
||||||
|
* - Redirecting output does not work on MS-Windows.
|
||||||
* - implement term_setsize()
|
* - implement term_setsize()
|
||||||
* - add test for giving error for invalid 'termsize' value.
|
* - add test for giving error for invalid 'termsize' value.
|
||||||
* - support minimal size when 'termsize' is "rows*cols".
|
* - support minimal size when 'termsize' is "rows*cols".
|
||||||
@ -56,6 +58,8 @@
|
|||||||
* - In the GUI use a terminal emulator for :!cmd.
|
* - In the GUI use a terminal emulator for :!cmd.
|
||||||
* - Copy text in the vterm to the Vim buffer once in a while, so that
|
* - Copy text in the vterm to the Vim buffer once in a while, so that
|
||||||
* completion works.
|
* completion works.
|
||||||
|
* - add an optional limit for the scrollback size. When reaching it remove
|
||||||
|
* 10% at the start.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "vim.h"
|
#include "vim.h"
|
||||||
@ -366,10 +370,10 @@ term_start(typval_T *argvar, jobopt_T *opt, int forceit)
|
|||||||
}
|
}
|
||||||
else if (argvar->v_type != VAR_LIST
|
else if (argvar->v_type != VAR_LIST
|
||||||
|| argvar->vval.v_list == NULL
|
|| argvar->vval.v_list == NULL
|
||||||
|| argvar->vval.v_list->lv_len < 1)
|
|| argvar->vval.v_list->lv_len < 1
|
||||||
|
|| (cmd = get_tv_string_chk(
|
||||||
|
&argvar->vval.v_list->lv_first->li_tv)) == NULL)
|
||||||
cmd = (char_u*)"";
|
cmd = (char_u*)"";
|
||||||
else
|
|
||||||
cmd = get_tv_string_chk(&argvar->vval.v_list->lv_first->li_tv);
|
|
||||||
|
|
||||||
len = STRLEN(cmd) + 10;
|
len = STRLEN(cmd) + 10;
|
||||||
p = alloc((int)len);
|
p = alloc((int)len);
|
||||||
|
@ -769,6 +769,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
1061,
|
||||||
/**/
|
/**/
|
||||||
1060,
|
1060,
|
||||||
/**/
|
/**/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user