unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Problem report #127: base/src/emacs/src/ftfont.c (ftfont_list_family); UNINIT
@ 2008-12-03  1:04 Dan Nicolaescu
  2008-12-03  5:00 ` Chong Yidong
  0 siblings, 1 reply; 2+ messages in thread
From: Dan Nicolaescu @ 2008-12-03  1:04 UTC (permalink / raw)
  To: emacs-devel


CID: 127
Checker: UNINIT (help)
File: base/src/emacs/src/ftfont.c
Function: ftfont_list_family
Description: Using uninitialized value "list"


Event var_decl: Declared variable "list" without initializer
Also see events: [uninit_use]

973  	  Lisp_Object list;
974  	  FcPattern *pattern = NULL;
975  	  FcFontSet *fontset = NULL;
976  	  FcObjectSet *objset = NULL;
977  	  int i;
978  	

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

979  	  if (! fc_initialized)
980  	    {
981  	      FcInit ();
982  	      fc_initialized = 1;
983  	    }
984  	
985  	  pattern = FcPatternCreate ();

At conditional (2): "pattern == 0" taking true path

986  	  if (! pattern)
987  	    goto finish;
988  	  objset = FcObjectSetBuild (FC_FAMILY, NULL);
989  	  if (! objset)
990  	    goto finish;
991  	  fontset = FcFontList (NULL, pattern, objset);
992  	  if (! fontset)
993  	    goto finish;
994  	
995  	  list = Qnil;
996  	  for (i = 0; i < fontset->nfont; i++)
997  	    {
998  	      FcPattern *pat = fontset->fonts[i];
999  	      FcChar8 *str;
1000 	
1001 	      if (FcPatternGetString (pat, FC_FAMILY, 0, &str) == FcResultMatch)
1002 		list = Fcons (intern ((char *) str), list);
1003 	    }
1004 	
1005 	 finish:

At conditional (3): "objset != 0" taking false path

1006 	  if (objset) FcObjectSetDestroy (objset);

At conditional (4): "fontset != 0" taking false path

1007 	  if (fontset) FcFontSetDestroy (fontset);

At conditional (5): "pattern != 0" taking false path

1008 	  if (pattern) FcPatternDestroy (pattern);
1009 	

Event uninit_use: Using uninitialized value "list"
Also see events: [var_decl]

1010 	  return list;
1011 	}
1012 	
1013 	




^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Problem report #127: base/src/emacs/src/ftfont.c (ftfont_list_family); UNINIT
  2008-12-03  1:04 Problem report #127: base/src/emacs/src/ftfont.c (ftfont_list_family); UNINIT Dan Nicolaescu
@ 2008-12-03  5:00 ` Chong Yidong
  0 siblings, 0 replies; 2+ messages in thread
From: Chong Yidong @ 2008-12-03  5:00 UTC (permalink / raw)
  To: Dan Nicolaescu; +Cc: emacs-devel

Dan Nicolaescu <dann@ics.uci.edu> writes:

> CID: 127
> Checker: UNINIT (help)
> File: base/src/emacs/src/ftfont.c
> Function: ftfont_list_family
> Description: Using uninitialized value "list"

Fixed, thanks.




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-12-03  5:00 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:04 Problem report #127: base/src/emacs/src/ftfont.c (ftfont_list_family); UNINIT Dan Nicolaescu
2008-12-03  5:00 ` Chong Yidong

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).