From: Sergey Senozhatsky <sergey.senozhatsky at gmail.com>
To: powertop@lists.01.org
Subject: [Powertop] [PATCH] tab_window: null members on construction
Date: Wed, 19 Dec 2012 19:06:52 +0300 [thread overview]
Message-ID: <20121219160652.GC3200@swordfish.minsk.epam.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 794 bytes --]
introduce tab_window ctor and null memebers during construction. show_tab() may be
called before window_refresh() [which sets ypad_pos and xpad_pos to 0], causing prefresh()
call with uninit win->ypad_pos, win->xpad_pos args.
Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky(a)gmail.com>
---
src/display.h | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/src/display.h b/src/display.h
index b450f8b..9af3ec0 100644
--- a/src/display.h
+++ b/src/display.h
@@ -53,6 +53,14 @@ public:
short int xpad_pos, ypad_pos;
WINDOW *win;
+ tab_window() {
+ cursor_pos = 0;
+ cursor_max = 0;
+ xpad_pos =0;
+ ypad_pos = 0;
+ win = NULL;
+ }
+
virtual void cursor_down(void) {
if (cursor_pos < cursor_max ) cursor_pos++; repaint();
} ;
next reply other threads:[~2012-12-19 16:06 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-19 16:06 Sergey Senozhatsky [this message]
-- strict thread matches above, loose matches on Subject: below --
2013-01-31 22:45 [Powertop] [PATCH] tab_window: null members on construction Kristen Carlson Accardi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20121219160652.GC3200@swordfish.minsk.epam.com \
--to=powertop@lists.01.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.