summary refs log tree commit diff
path: root/bin
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2021-10-25 14:01:55 -0400
committerJune McEnroe <june@causal.agency>2021-10-25 14:01:55 -0400
commitcc32e9bc9b980457641746878a3abf95f794d5fb (patch)
tree5dfd326a322f5f78f4a405c5225c99239a54f6ec /bin
parentOnly match first Nm for feed (diff)
downloadsrc-cc32e9bc9b980457641746878a3abf95f794d5fb.tar.gz
src-cc32e9bc9b980457641746878a3abf95f794d5fb.zip
Bounds check color indexes
Diffstat (limited to '')
-rw-r--r--bin/shotty.l2
1 files changed, 1 insertions, 1 deletions
diff --git a/bin/shotty.l b/bin/shotty.l
index c33b1f8b..c676d15b 100644
--- a/bin/shotty.l
+++ b/bin/shotty.l
@@ -498,7 +498,7 @@ static void span(const struct Cell *prev, const struct Cell *cell) {
 		if (attr & Bold) printf("font-weight:bold;");
 		if (attr & Italic) printf("font-style:italic;");
 		if (attr & Underline) printf("text-decoration:underline;");
-		if (colors) {
+		if (colors && bg < 256 && fg < 256) {
 			printf(
 				"background-color:#%06X;color:#%06X;",
 				Palette[bg], Palette[fg]
=1'>Update macOS neovim to 0.3.8June McEnroe 2019-07-27Rewrite port makefiles consistentlyJune McEnroe 2019-07-27Rewrite Makefile once more with more organizationJune McEnroe 2019-07-27Reference png.h in bin.7June McEnroe 2019-07-27Revert "Use scheme to style HTMLs"June McEnroe 2019-07-27Remove scheme text linkJune McEnroe 2019-07-26Update Dark.terminalJune McEnroe 2019-07-26Lighten dark whiteJune McEnroe 2019-07-25Add png.3 man pageJune McEnroe 2019-07-25Use scheme to style HTMLsJune McEnroe 2019-07-25Don't match comments in strings in makeJune McEnroe 2019-07-25Generate index.html with links from bin.7June McEnroe 2019-07-24Warn when date has changedJune McEnroe 2019-07-24Add whenJune McEnroe 2019-07-24Remove histedit from bitJune McEnroe