]> granicus.if.org Git - graphviz/commitdiff
htmltable: initialize a variable
authorCosta Shulyupin <constantine.shulyupin@gmail.com>
Sun, 27 Mar 2022 03:51:12 +0000 (06:51 +0300)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 2 Apr 2022 18:59:53 +0000 (11:59 -0700)
Squash
warning: ‘mxysize’ may be used uninitialized in this function [-Wmaybe-uninitialized]

lib/common/htmltable.c

index 83c021cc70c805fa79a656d116fb448c0d925379..c9cf88e081478d7634c3cda12fda9d7833090abd 100644 (file)
@@ -951,7 +951,7 @@ static int size_html_txt(GVC_t *gvc, htmltxt_t * ftxt, htmlenv_t * env)
     double width;
     textspan_t lp;
     textfont_t tf = {NULL,NULL,NULL,0.0,0,0};
-    double maxoffset, mxysize;
+    double maxoffset, mxysize = 0.0;
     bool simple = true; // one item per span, same font size/face, no flags
     double prev_fsize = -1;
     char* prev_fname = NULL;