mirror of
https://github.com/VARCem/PDCurses.git
synced 2026-09-25 00:05:16 +00:00
libpayload/PDcurses: avoid NULL deref
Found by Coverity Scan Signed-off-by: Patrick Georgi <patrick@georgi-clan.de> Signed-off-by: Stefan Reinauer <stefan.reinauer@coreboot.org> Reviewed-on: http://review.coreboot.org/7973
This commit is contained in:
committed by
William McBrine
parent
060c80a90b
commit
5325c5da24
@@ -84,14 +84,14 @@ int clrtoeol(void)
|
||||
|
||||
int wclrtobot(WINDOW *win)
|
||||
{
|
||||
int savey = win->_cury;
|
||||
int savex = win->_curx;
|
||||
|
||||
PDC_LOG(("wclrtobot() - called\n"));
|
||||
|
||||
if (!win)
|
||||
return ERR;
|
||||
|
||||
int savey = win->_cury;
|
||||
int savex = win->_curx;
|
||||
|
||||
/* should this involve scrolling region somehow ? */
|
||||
|
||||
if (win->_cury + 1 < win->_maxy)
|
||||
|
||||
Reference in New Issue
Block a user