* Problem report #126: base/src/emacs/src/font.c (font_at); UNINIT
@ 2008-12-03 1:03 Dan Nicolaescu
2008-12-03 5:54 ` Kenichi Handa
0 siblings, 1 reply; 2+ messages in thread
From: Dan Nicolaescu @ 2008-12-03 1:03 UTC (permalink / raw)
To: emacs-devel
CID: 126
Checker: UNINIT (help)
File: base/src/emacs/src/font.c
Function: font_at
Description: Using uninitialized value "multibyte"
Event var_decl: Declared variable "multibyte" without initializer
Also see events: [uninit_use]
3594 int multibyte;
3595 Lisp_Object font_object;
3596
At conditional (1): "c < 0" taking false path
3597 if (c < 0)
3598 {
3599 if (NILP (string))
3600 {
3601 multibyte = ! NILP (current_buffer->enable_multibyte_characters);
3602 if (multibyte)
3603 {
3604 EMACS_INT pos_byte = CHAR_TO_BYTE (pos);
3605
3606 c = FETCH_CHAR (pos_byte);
3607 }
3608 else
3609 c = FETCH_BYTE (pos);
3610 }
3611 else
3612 {
3613 unsigned char *str;
3614
3615 multibyte = STRING_MULTIBYTE (string);
3616 if (multibyte)
3617 {
3618 EMACS_INT pos_byte = string_char_to_byte (string, pos);
3619
3620 str = SDATA (string) + pos_byte;
3621 c = STRING_CHAR (str, 0);
3622 }
3623 else
3624 c = SDATA (string)[pos];
3625 }
3626 }
3627
3628 f = XFRAME (w->frame);
At conditional (2): "(f)->output_method != 2" taking false path
3629 if (! FRAME_WINDOW_P (f))
3630 return Qnil;
At conditional (3): "face == 0" taking true path
3631 if (! face)
3632 {
3633 int face_id;
3634 EMACS_INT endptr;
3635
At conditional (4): "string & 7 == 3" taking true path
3636 if (STRINGP (string))
3637 face_id = face_at_string_position (w, string, pos, 0, -1, -1, &endptr,
3638 DEFAULT_FACE_ID, 0);
3639 else
3640 face_id = face_at_buffer_position (w, pos, -1, -1, &endptr,
3641 pos + 100, 0);
At conditional (5): "face_id < ((f)->face_cache)->used" taking true path
3642 face = FACE_FROM_ID (f, face_id);
3643 }
Event uninit_use: Using uninitialized value "multibyte"
Also see events: [var_decl]
3644 if (multibyte)
3645 {
3646 int face_id = FACE_FOR_CHAR (f, face, c, pos, string);
3647 face = FACE_FROM_ID (f, face_id);
3648 }
3649 if (! face->font)
3650 return Qnil;
3651
3652 XSETFONT (font_object, face->font);
3653 return font_object;
3654 }
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Problem report #126: base/src/emacs/src/font.c (font_at); UNINIT
2008-12-03 1:03 Problem report #126: base/src/emacs/src/font.c (font_at); UNINIT Dan Nicolaescu
@ 2008-12-03 5:54 ` Kenichi Handa
0 siblings, 0 replies; 2+ messages in thread
From: Kenichi Handa @ 2008-12-03 5:54 UTC (permalink / raw)
To: Dan Nicolaescu; +Cc: emacs-devel
In article <200812030120.mB31KHZ9022807@mothra.ics.uci.edu>, Dan Nicolaescu <dann@ics.uci.edu> writes:
> CID: 126
> Checker: UNINIT (help)
> File: base/src/emacs/src/font.c
> Function: font_at
> Description: Using uninitialized value "multibyte"
Fixed.
---
Kenichi Handa
handa@ni.aist.go.jp
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-12-03 5:54 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-12-03 1:03 Problem report #126: base/src/emacs/src/font.c (font_at); UNINIT Dan Nicolaescu
2008-12-03 5:54 ` Kenichi Handa
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.