]> git.eshelyaron.com Git - emacs.git/commit
* term.c: Integer and memory overflow issues.
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 29 Jul 2011 01:22:19 +0000 (18:22 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 29 Jul 2011 01:22:19 +0000 (18:22 -0700)
commitfee31f82d5279a6faeb2d4cef808e9d7fce2f210
tree1bcce2fe8f01c58d4cd8958629254b894d622371
parentfe6442b1151a0f4021181e968479459f50df63f1
* term.c: Integer and memory overflow issues.

(max_frame_lines): Remove; unused.
(encode_terminal_src_size, encode_terminal_dst_size): Now ptrdiff_t,
not int.
(encode_terminal_code, calculate_costs): Check for size
calculation overflow.
(encode_terminal_code): Use ptrdiff_t, not int, to record glyph
table lengths and related sizes.  Don't update size until alloc
done.  Redo calculations to avoid overflow.
(calculate_costs): Don't bother calling xmalloc when xrealloc will do.
src/ChangeLog
src/term.c