summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@cvs.openbsd.org>2016-03-03 12:58:16 +0000
committerNicholas Marriott <nicm@cvs.openbsd.org>2016-03-03 12:58:16 +0000
commit3bb3a1ab7d649989017bddebea6b457ff8b273e6 (patch)
treedba2593d7c66a99b404f6e9d2dff0711a8985e48
parent08a786c1c4b16ae26bca8a5e3c31b8ccfd7bf0cb (diff)
RGB colours shouldn't be mixed up with aixterm colours, return before
that happens when working out if they are supported.
-rw-r--r--usr.bin/tmux/tty.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/usr.bin/tmux/tty.c b/usr.bin/tmux/tty.c
index 33c0012f409..5e795e70c30 100644
--- a/usr.bin/tmux/tty.c
+++ b/usr.bin/tmux/tty.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: tty.c,v 1.199 2016/01/29 11:13:56 nicm Exp $ */
+/* $OpenBSD: tty.c,v 1.200 2016/03/03 12:58:15 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicholas.marriott@gmail.com>
@@ -1569,6 +1569,8 @@ tty_check_fg(struct tty *tty, struct grid_cell *gc)
gc->flags |= GRID_FLAG_FG256;
gc->fg = colour_find_rgb(rgb->r, rgb->g, rgb->b);
}
+ else
+ return;
}
colours = tty_term_number(tty->term, TTYC_COLORS);
@@ -1612,6 +1614,8 @@ tty_check_bg(struct tty *tty, struct grid_cell *gc)
gc->flags |= GRID_FLAG_BG256;
gc->bg = colour_find_rgb(rgb->r, rgb->g, rgb->b);
}
+ else
+ return;
}
colours = tty_term_number(tty->term, TTYC_COLORS);