aboutsummaryrefslogtreecommitdiffstats
path: root/fm.h
diff options
context:
space:
mode:
authorTatsuya Kinoshita <tats@debian.org>2021-04-10 23:18:36 +0000
committerTatsuya Kinoshita <tats@debian.org>2021-04-24 14:39:52 +0000
commit56ce2a2cc8c31a2e57a5055132c0caa626c9c67c (patch)
treece58563488439cbe0f4b58fc9aa940f4fd571d3b /fm.h
parentCheck length of hostname with STR_SIZE_MAX (diff)
downloadw3m-56ce2a2cc8c31a2e57a5055132c0caa626c9c67c.tar.gz
w3m-56ce2a2cc8c31a2e57a5055132c0caa626c9c67c.zip
Prevent integer overflow due to fontstat
Diffstat (limited to '')
-rw-r--r--fm.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/fm.h b/fm.h
index b6d91fb..fb31e84 100644
--- a/fm.h
+++ b/fm.h
@@ -583,6 +583,7 @@ typedef struct _DownloadList {
#define FONT_STACK_SIZE 5
#define FONTSTAT_SIZE 7
+#define FONTSTAT_MAX 127
#define _INIT_BUFFER_WIDTH (COLS - (showLineNum ? 6 : 1))
#define INIT_BUFFER_WIDTH ((_INIT_BUFFER_WIDTH > 0) ? _INIT_BUFFER_WIDTH : 0)