[prev in list] [next in list] [prev in thread] [next in thread]
List: varnish-commit
Subject: [master] bd35552 Use the presentation mode for controlling the way a field is rendered in varnishsta
From: Martin Blix Grydeland <martin () varnish-software ! com>
Date: 2015-01-27 16:17:56
Message-ID: E1YG8pw-0003K9-K9 () project ! varnish-software ! com
[Download RAW message or body]
commit bd3555260e4f148fa6c76a63697996a9bdcd7454
Author: Martin Blix Grydeland <martin@varnish-software.com>
Date: Fri Jan 16 15:55:17 2015 +0100
Use the presentation mode for controlling the way a field is rendered in varnishstat
diff --git a/bin/varnishstat/varnishstat_curses.c b/bin/varnishstat/varnishstat_curses.c
index 4294999..48ae7fe 100644
--- a/bin/varnishstat/varnishstat_curses.c
+++ b/bin/varnishstat/varnishstat_curses.c
@@ -80,6 +80,7 @@ struct pt {
char *key;
char *name;
int semantics;
+ int format;
const volatile uint64_t *ptr;
char seen;
@@ -317,6 +318,7 @@ build_pt_list_cb(void *priv, const struct VSC_point *vpt)
pt->ptr = vpt->ptr;
pt->last = *pt->ptr;
pt->semantics = vpt->desc->semantics;
+ pt->format = vpt->desc->format;
pt->ma_10.nmax = 10;
pt->ma_100.nmax = 100;
@@ -692,7 +694,7 @@ draw_line_bitmap(WINDOW *w, int y, int x, int X, struct pt *pt)
AN(w);
AN(pt);
- assert(pt->semantics == 'b');
+ assert(pt->format == 'b');
col = 0;
while (col < COL_LAST) {
@@ -737,7 +739,7 @@ draw_line(WINDOW *w, int y, struct pt *pt)
mvwprintw(w, y, x, "%.*s", colw_name, pt->name);
x += colw_name;
- if (pt->semantics == 'b')
+ if (pt->format == 'b')
draw_line_bitmap(w, y, x, X, pt);
else
draw_line_default(w, y, x, X, pt);
_______________________________________________
varnish-commit mailing list
varnish-commit@varnish-cache.org
https://www.varnish-cache.org/lists/mailman/listinfo/varnish-commit
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic