mirror of
https://github.com/neovim/neovim.git
synced 2025-09-15 15:58:17 +00:00
Fix warnings: ex_cmds2.c: ex_listdo(): Np dereference: FP.
Problem : Dereference of null pointer @ 1903. Diagnostic : False positive. Rationale : Suggested error path first assumes wp == NULL and later one win_valid(wp), which is not possible. Resolution : Assert wp != NULL if win_valid(wp).
This commit is contained in:
@@ -1897,6 +1897,7 @@ void ex_listdo(exarg_T *eap)
|
||||
/* go to window "wp" */
|
||||
if (!win_valid(wp))
|
||||
break;
|
||||
assert(wp);
|
||||
win_goto(wp);
|
||||
if (curwin != wp)
|
||||
break; /* something must be wrong */
|
||||
|
Reference in New Issue
Block a user