Fix crash in lookup_image on termcap frames.
authorKaroly Lorentey <lorentey@elte.hu>
Fri, 30 Dec 2005 05:29:31 +0000 (05:29 +0000)
committerKaroly Lorentey <lorentey@elte.hu>
Fri, 30 Dec 2005 05:29:31 +0000 (05:29 +0000)
commit4a0e3f08607bbe80ad9dee2c441286f6ad695d0a
tree2a050c8ee5c8df1cb89fe68c69aef5178422cf65
parentea161626590293c1128cb327f1111a3c1500fe65
Fix crash in lookup_image on termcap frames.

* src/xdisp.c (get_glyph_string_clip_rects): Add extra parentheses and
  braces to prevent compiler warnings.
  (calc_pixel_width_or_height): Add xassert to check that the
  frame is alive.  Don't call `lookup_image' on a termcap frame.

* image.c (lookup_image): Don't initialize `c' until the xasserts have
  been run.

git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-476
src/image.c
src/xdisp.c