diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2016-08-31 08:55:32 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2016-08-31 08:55:32 (GMT) |
commit | 3710a862b304ce13a5d771616b45eaa556f201bc (patch) | |
tree | b89107a81aaee65f22938a9b9f99531a9877eefd /generic/tkSelect.c | |
parent | b237ee23c355f68d92dccd811aa8bfd6f1ceed05 (diff) | |
parent | 34d8945d9d1dbbb3f599cabcad75ec0305f7615d (diff) | |
download | tk-3710a862b304ce13a5d771616b45eaa556f201bc.zip tk-3710a862b304ce13a5d771616b45eaa556f201bc.tar.gz tk-3710a862b304ce13a5d771616b45eaa556f201bc.tar.bz2 |
Fix use of XMaxTransChars in stead of TCL_UTF_MAX in some places. This should prevent possible buffer overflow when TCL_UTF_MAX=6
Micro-optimizations in tkEntry and ttkEntry
Diffstat (limited to 'generic/tkSelect.c')
-rw-r--r-- | generic/tkSelect.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/generic/tkSelect.c b/generic/tkSelect.c index ab9018a..74b3964 100644 --- a/generic/tkSelect.c +++ b/generic/tkSelect.c @@ -26,7 +26,7 @@ typedef struct { int charOffset; /* The offset of the next char to retrieve. */ int byteOffset; /* The expected byte offset of the next * chunk. */ - char buffer[TCL_UTF_MAX]; /* A buffer to hold part of a UTF character + char buffer[4]; /* A buffer to hold part of a UTF character * that is split across chunks. */ char command[1]; /* Command to invoke. Actual space is * allocated as large as necessary. This must |