emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Problem report #92


From: Dan Nicolaescu
Subject: Problem report #92
Date: Thu, 07 Sep 2006 14:46:58 -0700

This appeared around August 25th. Can somebody please take a look and
see whether it's a real problem or not. 

Thanks!

CID: 92
Checker: UNINIT (help)
File: base/src/emacs/src/xterm.c
Function: x_draw_glyph_string
Description: Using uninitialized value "y" as argument to function 
"XFillRectangle"


2680      if (!s->for_overlaps)
2681        {
2682          /* Draw underline.  */
2683          if (s->face->underline_p)
2684            {
2685              unsigned long tem, h;

Event var_decl: Declared variable "y" without initializer
Also see events: [uninit_arg][uninit_arg]

2686              int y;
2687    
2688              /* Get the underline thickness.  Default is 1 pixel.  */

At conditional (1): "XGetFontProperty == 0" taking true path

2689              if (!XGetFontProperty (s->font, XA_UNDERLINE_THICKNESS, &h))
2690                h = 1;
2691    

At conditional (2): "x_underline_at_descent_line != 0" taking false path

2692              if (x_underline_at_descent_line)
2693                y = s->y + s->height - h;
2694              else
2695                {
2696                  /* Get the underline position.  This is the recommended
2697                     vertical offset in pixels from the baseline to the top 
of
2698                     the underline.  This is a signed value according to the
2699                     specs, and its default is
2700    
2701                     ROUND ((maximum descent) / 2), with
2702                     ROUND(x) = floor (x + 0.5)  */
2703    

At conditional (3): "x_use_underline_position_properties != 0" taking true path
At conditional (4): "XGetFontProperty != 0" taking false path

2704                  if (x_use_underline_position_properties
2705                      && XGetFontProperty (s->font, XA_UNDERLINE_POSITION, 
&tem))
2706                    y = s->ybase + (long) tem;

At conditional (5): "((s)->face)->font != 0" taking false path

2707                  else if (s->face->font)
2708                    y = s->ybase + (s->face->font->max_bounds.descent + 1) 
/ 2;
2709                }
2710    

At conditional (6): "((s)->face)->underline_defaulted_p != 0" taking true path

2711              if (s->face->underline_defaulted_p)

Event uninit_arg: Using uninitialized value "y" as argument to function 
"XFillRectangle"
Also see events: [var_decl][uninit_arg]

2712                XFillRectangle (s->display, s->window, s->gc,
2713                                s->x, y, s->background_width, h);
2714              else
2715                {
2716                  XGCValues xgcv;
2717                  XGetGCValues (s->display, s->gc, GCForeground, &xgcv);
2718                  XSetForeground (s->display, s->gc, 
s->face->underline_color);

Event uninit_arg: Using uninitialized value "y" as argument to function 
"XFillRectangle"
Also see events: [var_decl][uninit_arg]

2719                  XFillRectangle (s->display, s->window, s->gc,
2720                                  s->x, y, s->background_width, h);
2721                  XSetForeground (s->display, s->gc, xgcv.foreground);
2722                }
2723            }
2724    
2725          /* Draw overline.  */
2726          if (s->face->overline_p)
2727            {




reply via email to

[Prev in Thread] Current Thread [Next in Thread]