Stefan Reinauer (stefan.reinauer@coreboot.org) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/2906
-gerrit
commit 1614e1eb3e531708cf75a11bd4bcd7683d9d0634 Author: Stefan Reinauer reinauer@chromium.org Date: Mon Mar 25 15:30:30 2013 -0700
libpayload: Fix variable shadowing in PDCurses
PDCurses has a function called overlay() and also uses overlay as a variable name in some functions.
This patch fixes the ambiguity that caused warnings like curses/PDCurses-3.4/pdcurses/overlay.c: In function '_copy_win': curses/PDCurses-3.4/pdcurses/overlay.c:51:39: warning: declaration of 'overlay' shadows a global declaration [-Wshadow] In file included from curses/PDCurses-3.4/curspriv.h:16:0, from curses/PDCurses-3.4/pdcurses/overlay.c:3: curses/PDCurses-3.4/curses.h:1014:9: warning: shadowed declaration is here [-Wshadow]
Change-Id: I907653df0c8bb32c98bdcbc6476e94d2da6e0e90 Signed-off-by: Stefan Reinauer reinauer@google.com --- payloads/libpayload/curses/PDCurses-3.4/pdcurses/overlay.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/payloads/libpayload/curses/PDCurses-3.4/pdcurses/overlay.c b/payloads/libpayload/curses/PDCurses-3.4/pdcurses/overlay.c index a1d5791..d1e9f21 100644 --- a/payloads/libpayload/curses/PDCurses-3.4/pdcurses/overlay.c +++ b/payloads/libpayload/curses/PDCurses-3.4/pdcurses/overlay.c @@ -48,7 +48,7 @@ RCSID("$Id: overlay.c,v 1.36 2008/07/14 12:35:23 wmcbrine Exp $")
static int _copy_win(const WINDOW *src_w, WINDOW *dst_w, int src_tr, int src_tc, int src_br, int src_bc, int dst_tr, - int dst_tc, bool overlay) + int dst_tc, bool _overlay) { int col, line, y1, fc, *minchng, *maxchng; chtype *w1ptr, *w2ptr; @@ -79,7 +79,7 @@ static int _copy_win(const WINDOW *src_w, WINDOW *dst_w, int src_tr, for (col = 0; col < xdiff; col++) { if ((*w1ptr) != (*w2ptr) && - !((*w1ptr & A_CHARTEXT) == ' ' && overlay)) + !((*w1ptr & A_CHARTEXT) == ' ' && _overlay)) { *w2ptr = *w1ptr;
@@ -228,7 +228,7 @@ int overwrite(const WINDOW *src_w, WINDOW *dst_w) }
int copywin(const WINDOW *src_w, WINDOW *dst_w, int src_tr, int src_tc, - int dst_tr, int dst_tc, int dst_br, int dst_bc, int overlay) + int dst_tr, int dst_tc, int dst_br, int dst_bc, int _overlay) { int src_end_x, src_end_y; int src_rows, src_cols, dst_rows, dst_cols; @@ -252,5 +252,5 @@ int copywin(const WINDOW *src_w, WINDOW *dst_w, int src_tr, int src_tc, src_end_x = src_tc + min_cols;
return _copy_win(src_w, dst_w, src_tr, src_tc, src_end_y, src_end_x, - dst_tr, dst_tc, overlay); + dst_tr, dst_tc, _overlay); }