lxpanel-0.11.1-1.fc43

List of Findings

Error: GCC_ANALYZER_WARNING (CWE-476): [#def1]
lxpanel-0.11.1/lxpanel/plugins/batt/batt.c:294:17: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL 'a'
lxpanel-0.11.1/lxpanel/plugins/batt/batt.c:377:17: enter_function: entry to 'buttonPressEvent'
lxpanel-0.11.1/lxpanel/plugins/batt/batt.c:382:5: call_function: calling 'update_display' from 'buttonPressEvent'
#  292|   
#  293|                   Alarm *a = (Alarm *) malloc(sizeof(Alarm));
#  294|->                 a->command = lx_b->alarmCommand;
#  295|                   a->lock = &(lx_b->alarmProcessLock);
#  296|   

Error: GCC_ANALYZER_WARNING (CWE-476): [#def2]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:92:52: warning[-Wanalyzer-null-dereference]: dereference of NULL '0'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:370:19: enter_function: entry to 'cpufreq_constructor'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:378:5: release_memory: '0' is NULL
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:379:5: release_memory: '0' is NULL
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:378:5: release_memory: '0' is NULL
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:379:5: release_memory: '0' is NULL
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:387:5: call_function: calling 'get_cpus' from 'cpufreq_constructor'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:387:5: return_function: returning to 'cpufreq_constructor' from 'get_cpus'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:393:5: call_function: calling '_update_tooltip' from 'cpufreq_constructor'
#   90|       char buf[ 100 ], sstmp [ 256 ];
#   91|   
#   92|->     snprintf(sstmp, sizeof(sstmp), "%s/%s", (char*)cf->cpus->data, SCALING_CUR_FREQ);
#   93|       if ((fp = fopen( sstmp, "r")) != NULL) {
#   94|           if (fgets(buf, 100, fp))

Error: COMPILER_WARNING (CWE-563): [#def3]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:106:12: warning[-Wunused-variable]: unused variable 'l'
#  106 |     GList *l;
#      |            ^
#  104|   get_governors(cpufreq *cf){
#  105|       FILE *fp;
#  106|->     GList *l;
#  107|       char buf[ 100 ], sstmp [ 256 ], c, bufl = 0;
#  108|   

Error: COMPILER_WARNING: [#def4]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c: scope_hint: In function 'get_governors'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:118:38: warning[-Wformat=]: format '%s' expects argument of type 'char *', but argument 4 has type 'gpointer' {aka 'void *'}
#  118 |     snprintf(sstmp, sizeof(sstmp), "%s/%s", cf->cpus->data, SCALING_AGOV);
#      |                                     ~^      ~~~~~~~~~~~~~~
#      |                                      |              |
#      |                                      char *         gpointer {aka void *}
#      |                                     %p
#  116|           return;
#  117|       }
#  118|->     snprintf(sstmp, sizeof(sstmp), "%s/%s", cf->cpus->data, SCALING_AGOV);
#  119|   
#  120|       if (!(fp = fopen( sstmp, "r"))) {

Error: COMPILER_WARNING (CWE-823): [#def5]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:128:20: warning[-Wchar-subscripts]: array subscript has type 'char'
#  128 |                 buf[bufl] = '\0';
#      |                    ^
#  126|           if(c == ' '){
#  127|               if(bufl > 1){
#  128|->                 buf[bufl] = '\0';
#  129|                   cf->governors = g_list_append(cf->governors, strdup(buf));
#  130|               }

Error: COMPILER_WARNING (CWE-823): [#def6]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:134:21: warning[-Wchar-subscripts]: array subscript has type 'char'
#  134 |             buf[bufl++] = c;
#      |                 ~~~~^~
#  132|               buf[0] = '\0';
#  133|           }else{
#  134|->             buf[bufl++] = c;
#  135|           }
#  136|       }

Error: COMPILER_WARNING: [#def7]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c: scope_hint: In function 'permission'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:186:36: warning[-Wformat=]: format '%s' expects argument of type 'char *', but argument 4 has type 'gpointer' {aka 'void *'}
#  186 |     snprintf(path, sizeof(path), "%s/%s", cf->cpus->data, file);
#      |                                   ~^      ~~~~~~~~~~~~~~
#      |                                    |              |
#      |                                    char *         gpointer {aka void *}
#      |                                   %p
#  184|       char path [ 256 ];
#  185|   
#  186|->     snprintf(path, sizeof(path), "%s/%s", cf->cpus->data, file);
#  187|       return (g_access(path, W_OK) == 0);
#  188|   }

Error: COMPILER_WARNING: [#def8]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c: scope_hint: In function 'frequency_menu'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:196:38: warning[-Wformat=]: format '%s' expects argument of type 'char *', but argument 4 has type 'gpointer' {aka 'void *'}
#  196 |     snprintf(sstmp, sizeof(sstmp), "%s/%s", cf->cpus->data, SCALING_AFREQ);
#      |                                     ~^      ~~~~~~~~~~~~~~
#      |                                      |              |
#      |                                      char *         gpointer {aka void *}
#      |                                     %p
#  194|       char buf[ 100 ], sstmp [ 256 ], c, bufl = 0;
#  195|   
#  196|->     snprintf(sstmp, sizeof(sstmp), "%s/%s", cf->cpus->data, SCALING_AFREQ);
#  197|   
#  198|       if (!(fp = fopen( sstmp, "r"))) {

Error: COMPILER_WARNING (CWE-823): [#def9]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:209:20: warning[-Wchar-subscripts]: array subscript has type 'char'
#  209 |                 buf[bufl] = '\0';
#      |                    ^
#  207|           if(c == ' '){
#  208|               if(bufl > 1){
#  209|->                 buf[bufl] = '\0';
#  210|                   menuitem = gtk_menu_item_new_with_label(strdup(buf));
#  211|                   gtk_menu_shell_append (GTK_MENU_SHELL (menu), menuitem);

Error: GCC_ANALYZER_WARNING (CWE-401): [#def10]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:211:17: warning[-Wanalyzer-malloc-leak]: leak of 'strdup(&buf)'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:330:1: enter_function: entry to 'clicked'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:338:23: call_function: calling 'cpufreq_menu' from 'clicked'
#  209|                   buf[bufl] = '\0';
#  210|                   menuitem = gtk_menu_item_new_with_label(strdup(buf));
#  211|->                 gtk_menu_shell_append (GTK_MENU_SHELL (menu), menuitem);
#  212|                   gtk_widget_show (menuitem);
#  213|                   param = g_new0(Param, 1);

Error: COMPILER_WARNING (CWE-823): [#def11]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:222:21: warning[-Wchar-subscripts]: array subscript has type 'char'
#  222 |             buf[bufl++] = c;
#      |                 ~~~~^~
#  220|               buf[0] = '\0';
#  221|           }else{
#  222|->             buf[bufl++] = c;
#  223|           }
#  224|       }

Error: COMPILER_WARNING (CWE-563): [#def12]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:270:13: warning[-Wunused-but-set-variable]: variable 'group' set but not used
#  270 |     GSList *group;
#      |             ^~~~~
#  268|   cpufreq_menu(cpufreq *cf){
#  269|       GList *l;
#  270|->     GSList *group;
#  271|       gboolean can_write;
#  272|       char buff[100];

Error: COMPILER_WARNING: [#def13]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c: scope_hint: In function 'cpufreq_menu'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:307:43: warning[-Wformat=]: format '%s' expects argument of type 'char *', but argument 4 has type 'gpointer' {aka 'void *'}
#  307 |         snprintf(buff, sizeof(buff), "▸  %s", l->data);
#      |                                          ~^   ~~~~~~~
#      |                                           |    |
#      |                                           |    gpointer {aka void *}
#      |                                           char *
#      |                                          %p
#  305|       {
#  306|         if(strcmp((char*)l->data, cf->cur_governor) == 0){
#  307|->         snprintf(buff, sizeof(buff), "▸  %s", l->data);
#  308|           menuitem = GTK_MENU_ITEM(gtk_menu_item_new_with_label(strdup(buff)));
#  309|         }else{

Error: GCC_ANALYZER_WARNING (CWE-401): [#def14]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:308:20: warning[-Wanalyzer-malloc-leak]: leak of 'strdup(&buff)'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:330:1: enter_function: entry to 'clicked'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:338:23: call_function: calling 'cpufreq_menu' from 'clicked'
#  306|         if(strcmp((char*)l->data, cf->cur_governor) == 0){
#  307|           snprintf(buff, sizeof(buff), "▸  %s", l->data);
#  308|->         menuitem = GTK_MENU_ITEM(gtk_menu_item_new_with_label(strdup(buff)));
#  309|         }else{
#  310|           snprintf(buff, sizeof(buff), "   %s", l->data);

Error: COMPILER_WARNING: [#def15]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:310:43: warning[-Wformat=]: format '%s' expects argument of type 'char *', but argument 4 has type 'gpointer' {aka 'void *'}
#  310 |         snprintf(buff, sizeof(buff), "   %s", l->data);
#      |                                          ~^   ~~~~~~~
#      |                                           |    |
#      |                                           |    gpointer {aka void *}
#      |                                           char *
#      |                                          %p
#  308|           menuitem = GTK_MENU_ITEM(gtk_menu_item_new_with_label(strdup(buff)));
#  309|         }else{
#  310|->         snprintf(buff, sizeof(buff), "   %s", l->data);
#  311|           menuitem = GTK_MENU_ITEM(gtk_menu_item_new_with_label(strdup(buff)));
#  312|         }

Error: GCC_ANALYZER_WARNING (CWE-401): [#def16]
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:311:20: warning[-Wanalyzer-malloc-leak]: leak of 'strdup(&buff)'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:330:1: enter_function: entry to 'clicked'
lxpanel-0.11.1/lxpanel/plugins/cpufreq/cpufreq.c:338:23: call_function: calling 'cpufreq_menu' from 'clicked'
#  309|         }else{
#  310|           snprintf(buff, sizeof(buff), "   %s", l->data);
#  311|->         menuitem = GTK_MENU_ITEM(gtk_menu_item_new_with_label(strdup(buff)));
#  312|         }
#  313|   

Error: COMPILER_WARNING (CWE-477): [#def17]
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-icon.c: scope_hint: In function 'netstatus_icon_get_default_pixbuf'
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-icon.c:105:7: warning[-Wdeprecated-declarations]: 'gdk_pixbuf_new_from_inline' is deprecated
#  105 |       fallback_pixbuf = gdk_pixbuf_new_from_inline (-1,
#      |       ^~~~~~~~~~~~~~~
/usr/include/gdk-pixbuf-2.0/gdk-pixbuf/gdk-pixbuf.h:34: included_from: Included from here.
/usr/include/gtk-2.0/gdk/gdkpixbuf.h:37: included_from: Included from here.
/usr/include/gtk-2.0/gdk/gdkcairo.h:28: included_from: Included from here.
/usr/include/gtk-2.0/gdk/gdk.h:33: included_from: Included from here.
/usr/include/gdk-pixbuf-2.0/gdk-pixbuf/gdk-pixbuf-core.h:298:12: note: declared here
#  298 | GdkPixbuf* gdk_pixbuf_new_from_inline   (gint          data_length,
#      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~
#  103|     if (!fallback_pixbuf)
#  104|       {
#  105|->       fallback_pixbuf = gdk_pixbuf_new_from_inline (-1,
#  106|   						    fallback_icon_data,
#  107|   						    FALSE,

Error: COMPILER_WARNING (CWE-477): [#def18]
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-icon.c:105:7: warning[-Wdeprecated-declarations]: 'gdk_pixbuf_new_from_inline' is deprecated
#  103|     if (!fallback_pixbuf)
#  104|       {
#  105|->       fallback_pixbuf = gdk_pixbuf_new_from_inline (-1,
#  106|   						    fallback_icon_data,
#  107|   						    FALSE,

Error: COMPILER_WARNING (CWE-252): [#def19]
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-iface.c:787:3: warning[-Wunused-result]: ignoring return value of 'g_string_free_and_steal' declared with attribute '[warn_unused_result](https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-warn_005funused_005fresult-function-attribute)'
#  785|   
#  786|     retval = str->str;
#  787|->   g_string_free (str, FALSE);
#  788|   
#  789|     return retval;

Error: COMPILER_WARNING (CWE-252): [#def20]
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-iface.c:810:11: warning[-Wunused-result]: ignoring return value of 'g_string_free_and_steal' declared with attribute '[warn_unused_result](https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-warn_005funused_005fresult-function-attribute)'
#  808|   	{
#  809|   	  retval = str->str;
#  810|-> 	  g_string_free (str, FALSE);
#  811|   
#  812|   	  return retval;

Error: COMPILER_WARNING (CWE-252): [#def21]
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-iface.c:823:3: warning[-Wunused-result]: ignoring return value of 'g_string_free_and_steal' declared with attribute '[warn_unused_result](https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-warn_005funused_005fresult-function-attribute)'
#  821|   
#  822|     retval = str->str;
#  823|->   g_string_free (str, FALSE);
#  824|   
#  825|     return retval;

Error: COMPILER_WARNING (CWE-697): [#def22]
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-iface.c: scope_hint: In function 'netstatus_iface_get_hw_details'
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-iface.c:1074:15: warning[-Waddress]: the comparison will always evaluate as 'true' for the address of 'sa_data' will never be NULL
# 1074 |   if (hw_addr && if_req.ifr_hwaddr.sa_data && hw_type->print_hw_addr)
#      |               ^~
/usr/include/sys/socket.h:33: included_from: Included from here.
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-iface.c:43: included_from: Included from here.
/usr/include/bits/socket.h:187:10: note: 'sa_data' declared here
#  187 |     char sa_data[14];           /* Address data.  */
#      |          ^~~~~~~
# 1072|       }
# 1073|   
# 1074|->   if (hw_addr && if_req.ifr_hwaddr.sa_data && hw_type->print_hw_addr)
# 1075|       *hw_addr = hw_type->print_hw_addr ((guchar *) if_req.ifr_hwaddr.sa_data);
# 1076|   

Error: COMPILER_WARNING (CWE-477): [#def23]
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-util.c: scope_hint: In function 'netstatus_stats_copy'
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-util.c:84:3: warning[-Wdeprecated-declarations]: 'g_memdup' is deprecated: Use 'g_memdup2' instead
#   84 |   return (NetstatusStats *)g_memdup (stats, sizeof (NetstatusStats));
#      |   ^~~~~~
/usr/include/glib-2.0/glib/gstring.h:37: included_from: Included from here.
/usr/include/glib-2.0/glib/giochannel.h:36: included_from: Included from here.
/usr/include/glib-2.0/glib.h:56: included_from: Included from here.
/usr/include/glib-2.0/gobject/gbinding.h:30: included_from: Included from here.
/usr/include/glib-2.0/glib-object.h:24: included_from: Included from here.
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-util.h:27: included_from: Included from here.
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-util.c:27: included_from: Included from here.
/usr/include/glib-2.0/glib/gstrfuncs.h:338:23: note: declared here
#  338 | gpointer              g_memdup         (gconstpointer mem,
#      |                       ^~~~~~~~
#   82|   netstatus_stats_copy (NetstatusStats *stats)
#   83|   {
#   84|->   return (NetstatusStats *)g_memdup (stats, sizeof (NetstatusStats));
#   85|   }
#   86|   

Error: COMPILER_WARNING (CWE-477): [#def24]
lxpanel-0.11.1/lxpanel/plugins/netstatus/netstatus-util.c:84:3: warning[-Wdeprecated-declarations]: 'g_memdup' is deprecated: Use 'g_memdup2' instead
#   82|   netstatus_stats_copy (NetstatusStats *stats)
#   83|   {
#   84|->   return (NetstatusStats *)g_memdup (stats, sizeof (NetstatusStats));
#   85|   }
#   86|   

Error: GCC_ANALYZER_WARNING (CWE-476): [#def25]
lxpanel-0.11.1/lxpanel/plugins/tray.c:149:17: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘tc_pred’
lxpanel-0.11.1/lxpanel/plugins/tray.c:470:24: enter_function: entry to ‘tray_event_filter’
lxpanel-0.11.1/lxpanel/plugins/tray.c:472:8: branch_true: following ‘true’ branch...
lxpanel-0.11.1/lxpanel/plugins/tray.c:479:27: branch_true: ...to here
lxpanel-0.11.1/lxpanel/plugins/tray.c:479:27: call_function: inlined call to ‘client_lookup’ from ‘tray_event_filter’
lxpanel-0.11.1/lxpanel/plugins/tray.c:480:12: branch_true: following ‘true’ branch...
lxpanel-0.11.1/lxpanel/plugins/tray.c:481:13: branch_true: ...to here
lxpanel-0.11.1/lxpanel/plugins/tray.c:481:13: call_function: calling ‘client_delete’ from ‘tray_event_filter’
#  147|                 tc_pred = tc_cursor, tc_cursor = tc_cursor->client_flink) ;
#  148|               if (tc_cursor == tc)
#  149|->                 tc_pred->client_flink = tc->client_flink;
#  150|           }
#  151|       }

Error: CPPCHECK_WARNING (CWE-476): [#def26]
lxpanel-0.11.1/lxpanel/plugins/weather/openweathermap.c:669: warning[nullPointer]: Possible null pointer dereference: pcImageURL
#  667|                                     &pEntry->fAspectRatio,
#  668|                                     pcImageURL,
#  669|->                                   strlen(pcImageURL),
#  670|                                     &pEntry->pcBigImageURL_,
#  671|                                     &pEntry->pBigImage_,

Error: CPPCHECK_WARNING (CWE-476): [#def27]
lxpanel-0.11.1/lxpanel/plugins/weather/openweathermap.c:673: warning[nullPointer]: Possible null pointer dereference: pcBigImageURL
#  671|                                     &pEntry->pBigImage_,
#  672|                                     pcBigImageURL,
#  673|->                                   strlen(pcBigImageURL));
#  674|   
#  675|                 if (number && *number && atoi(number) < 800) /* not clear */

Error: GCC_ANALYZER_WARNING (CWE-688): [#def28]
lxpanel-0.11.1/lxpanel/plugins/weather/openweathermap.c:673:35: warning[-Wanalyzer-null-argument]: use of NULL 'pcBigImageURL' where non-null expected
lxpanel-0.11.1/lxpanel/plugins/weather/openweathermap.c:1003:22: enter_function: entry to 'getForecastInfo'
lxpanel-0.11.1/lxpanel/plugins/weather/openweathermap.c:1014:10: release_memory: 'pResponse' is NULL
lxpanel-0.11.1/lxpanel/plugins/weather/openweathermap.c:1023:7: release_memory: 'pResponse' is NULL
lxpanel-0.11.1/lxpanel/plugins/weather/openweathermap.c:1023:6: branch_false: following 'false' branch...
lxpanel-0.11.1/lxpanel/plugins/weather/openweathermap.c:1036:14: call_function: calling 'parseResponse' from 'getForecastInfo'
#argument 1 of '__builtin_strlen' must be non-null
#  671|                                     &pEntry->pBigImage_,
#  672|                                     pcBigImageURL,
#  673|->                                   strlen(pcBigImageURL));
#  674|   
#  675|                 if (number && *number && atoi(number) < 800) /* not clear */

Error: COMPILER_WARNING (CWE-477): [#def29]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c: scope_hint: In function 'gtk_weather_class_init'
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:273:3: warning[-Wdeprecated-declarations]: 'g_type_class_add_private' is deprecated
#  273 |   g_type_class_add_private(klass, sizeof(GtkWeatherPrivate));
#      |   ^~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/glib-2.0/gobject/gtype.h:1503:10: note: declared here
# 1503 | void     g_type_class_add_private       (gpointer                    g_class,
#      |          ^~~~~~~~~~~~~~~~~~~~~~~~
#  271|     widget_class->button_press_event = gtk_weather_button_pressed;
#  272|     
#  273|->   g_type_class_add_private(klass, sizeof(GtkWeatherPrivate));
#  274|   
#  275|     g_object_class_install_property(gobject_class, PROP_LOCATION,

Error: COMPILER_WARNING (CWE-477): [#def30]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:273:3: warning[-Wdeprecated-declarations]: 'g_type_class_add_private' is deprecated
#  271|     widget_class->button_press_event = gtk_weather_button_pressed;
#  272|     
#  273|->   g_type_class_add_private(klass, sizeof(GtkWeatherPrivate));
#  274|   
#  275|     g_object_class_install_property(gobject_class, PROP_LOCATION,

Error: COMPILER_WARNING: [#def31]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:321:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
#  319|     LXW_LOG(LXW_DEBUG, "GtkWeather::init()");
#  320|   
#  321|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
#  322|   
#  323|     /* Box layout internals */

Error: COMPILER_WARNING: [#def32]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:372:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
#  370|     GtkWeather * weather = GTK_WEATHER(object);
#  371|   
#  372|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
#  373|   
#  374|     if (priv->forecast_data.timerid > 0)

Error: COMPILER_WARNING: [#def33]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:409:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
#  407|       }
#  408|   
#  409|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(GTK_WEATHER(widget));
#  410|   
#  411|     LXW_LOG(LXW_DEBUG, "GtkWeather::size_allocate(%d): x: %d, y: %d, %dx%d (x: %d, y: %d, %dx%d)", 

Error: COMPILER_WARNING: [#def34]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:464:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
#  462|   gtk_weather_render(GtkWeather * weather)
#  463|   {
#  464|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
#  465|    
#  466|     LXW_LOG(LXW_DEBUG, "GtkWeather::render(): location: %p, forecast: %p",

Error: COMPILER_WARNING: [#def35]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:554:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
#  552|     GtkWeather * weather = GTK_WEATHER(object);
#  553|   
#  554|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
#  555|   
#  556|     LXW_LOG(LXW_DEBUG, "GtkWeather::set_property(%u - %s)", prop_id,

Error: COMPILER_WARNING: [#def36]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:599:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
#  597|   {
#  598|     GtkWeather * weather = GTK_WEATHER(object);
#  599|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
#  600|   
#  601|     switch (prop_id)

Error: COMPILER_WARNING: [#def37]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:628:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
#  626|   gtk_weather_set_location(GtkWeather * weather, gpointer location)
#  627|   {
#  628|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
#  629|   
#  630|     LXW_LOG(LXW_DEBUG, "GtkWeather::set_location(): current: %p, new: %p",

Error: COMPILER_WARNING: [#def38]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:670:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
#  668|   gtk_weather_set_forecast(GtkWeather * weather, ForecastInfo * forecast)
#  669|   {
#  670|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
#  671|   
#  672|     LXW_LOG(LXW_DEBUG, "GtkWeather::set_forecast(): current: %p, new: %p",

Error: COMPILER_WARNING: [#def39]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:695:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
#  693|   provider_callback_info * gtk_weather_get_provider(GtkWeather * weather)
#  694|   {
#  695|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
#  696|   
#  697|     return priv->provider;

Error: COMPILER_WARNING: [#def40]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:702:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
#  700|   int gtk_weather_set_provider(GtkWeather * weather, provider_callback_info * provider)
#  701|   {
#  702|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
#  703|     ProviderInfo * instance = NULL;
#  704|   

Error: COMPILER_WARNING: [#def41]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:736:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
#  734|   
#  735|     GtkWeather * weather = GTK_WEATHER(widget);
#  736|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
#  737|   
#  738|   #ifdef USE_STANDALONE

Error: COMPILER_WARNING: [#def42]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:770:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
#  768|     LXW_LOG(LXW_DEBUG, "GtkWeather::auto_update_toggled()");
#  769|   
#  770|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(GTK_WEATHER(widget));
#  771|   
#  772|     LocationInfo * location = priv->location;

Error: COMPILER_WARNING: [#def43]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:805:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
#  803|     (void)event;
#  804|   
#  805|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(GTK_WEATHER(widget));
#  806|   
#  807|     GtkWidget * dialog = gtk_dialog_new_with_buttons(_("Enter New Location"),

Error: COMPILER_WARNING: [#def44]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:1139:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
# 1137|     GtkWeather * weather = GTK_WEATHER(data);
# 1138|   
# 1139|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
# 1140|   
# 1141|     switch(response)

Error: COMPILER_WARNING: [#def45]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:1252:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
# 1250|     LXW_LOG(LXW_DEBUG, "GtkWeather::create_preferences_dialog()");
# 1251|   
# 1252|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
# 1253|   
# 1254|     priv->preferences_data.dialog = gtk_dialog_new_with_buttons(_("Weather Preferences"),

Error: COMPILER_WARNING: [#def46]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:1501:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
# 1499|     LXW_LOG(LXW_DEBUG, "GtkWeather::update_preferences_dialog()");
# 1500|   
# 1501|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
# 1502|   
# 1503|     if (!priv->preferences_data.dialog)

Error: COMPILER_WARNING: [#def47]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:1600:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
# 1598|     LXW_LOG(LXW_DEBUG, "GtkWeather::run_conditions_dialog()");
# 1599|   
# 1600|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
# 1601|   
# 1602|     LocationInfo * location = priv->location;

Error: COMPILER_WARNING: [#def48]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:1982:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
# 1980|     LXW_LOG(LXW_DEBUG, "GtkWeather::show_location_progress_bar()");
# 1981|   
# 1982|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
# 1983|   
# 1984|     gchar * progress_str = g_strdup_printf(_("Searching for '%s'..."), priv->location_data.location);

Error: COMPILER_WARNING: [#def49]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:2108:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
# 2106|     LXW_LOG(LXW_DEBUG, "GtkWeather::show_location_list(%d)", g_list_length(list));
# 2107|   
# 2108|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
# 2109|   
# 2110|     gchar * dialog_str = g_strdup_printf(_("Location matches for '%s'"), 

Error: COMPILER_WARNING: [#def50]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:2263:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
# 2261|   gtk_weather_get_tooltip_text(GtkWeather * weather)
# 2262|   {
# 2263|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
# 2264|   
# 2265|     LXW_LOG(LXW_DEBUG, "GtkWeather::get_tooltip_text()");

Error: COMPILER_WARNING: [#def51]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:2358:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
# 2356|     LXW_LOG(LXW_DEBUG, "GtkWeather::get_forecast()");
# 2357|   
# 2358|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(weather);
# 2359|   
# 2360|     LocationInfo * location = priv->location;

Error: COMPILER_WARNING: [#def52]
lxpanel-0.11.1/lxpanel/plugins/weather/weatherwidget.c:2425:30: warning[warning]: Deprecated pre-processor symbol: replace with "G_ADD_PRIVATE"
# 2423|   gtk_weather_get_forecast_timerfunc(gpointer data)
# 2424|   {
# 2425|->   GtkWeatherPrivate * priv = GTK_WEATHER_GET_PRIVATE(GTK_WEATHER(data));
# 2426|   
# 2427|     LXW_LOG(LXW_DEBUG, "GtkWeather::get_forecast_timerfunc(%d %d)", 

Error: COMPILER_WARNING (CWE-252): [#def53]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb-plugin.c:329:9: warning[-Wunused-result]: ignoring return value of 'g_string_free_and_steal' declared with attribute '[warn_unused_result](https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-warn_005funused_005fresult-function-attribute)'
#  327|           p_xkb->kbd_variants = variants->str;
#  328|   
#  329|->         g_string_free(layouts, FALSE);
#  330|           g_string_free(variants, FALSE);
#  331|   

Error: COMPILER_WARNING (CWE-252): [#def54]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb-plugin.c:330:9: warning[-Wunused-result]: ignoring return value of 'g_string_free_and_steal' declared with attribute '[warn_unused_result](https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-warn_005funused_005fresult-function-attribute)'
#  328|   
#  329|           g_string_free(layouts, FALSE);
#  330|->         g_string_free(variants, FALSE);
#  331|   
#  332|           p_xkb->kbd_model = g_strdup(xkb_get_model_name(p_xkb));

Error: COMPILER_WARNING (CWE-393): [#def55]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb-plugin.c: scope_hint: In function 'options_button'
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb-plugin.c:750:1: warning[-Wreturn-type]: no return statement in function returning non-void
#  750 | }
#      | ^
#  748|           gtk_label_set_max_width_chars(GTK_LABEL(label), 40);
#  749|       }
#  750|-> }
#  751|   
#  752|   static void on_button_kbd_change_layout_clicked(GtkButton *p_button, gpointer *p_data)

Error: COMPILER_WARNING (CWE-697): [#def56]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c: scope_hint: In function 'initialize_keyboard_description'
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:193:96: warning[-Waddress]: the comparison will always evaluate as 'false' for the address of 'groups' will never be NULL
#  193 |         if ((xkb_desc->names == NULL) || (xkb_desc->ctrls == NULL) || (xkb_desc->names->groups == NULL))
#      |                                                                                                ^~
/usr/include/X11/XKBlib.h:31: included_from: Included from here.
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.h:23: included_from: Included from here.
/usr/include/X11/extensions/XKBstr.h:424:27: note: 'groups' declared here
#  424 |         Atom              groups[XkbNumKbdGroups];
#      |                           ^~~~~~
#  191|           XkbGetControls(xdisplay, XkbAllControlsMask, xkb_desc);
#  192|           XkbGetNames(xdisplay, XkbSymbolsNameMask | XkbGroupNamesMask, xkb_desc);
#  193|->         if ((xkb_desc->names == NULL) || (xkb_desc->ctrls == NULL) || (xkb_desc->names->groups == NULL))
#  194|               g_warning("XkbGetControls/XkbGetNames failed\n");
#  195|           else

Error: COMPILER_WARNING (CWE-681): [#def57]
/usr/include/glib-2.0/glib/gstring.h:37: included_from: Included from here.
/usr/include/glib-2.0/glib/giochannel.h:36: included_from: Included from here.
/usr/include/glib-2.0/glib.h:56: included_from: Included from here.
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:246:65: warning[-Wpointer-sign]: pointer targets in passing argument 1 of 'g_strdup_inline' differ in signedness
#  246 |                                 xkb->model_name = g_strdup(prop + pos);
#      |                                                            ~~~~~^~~~~
#      |                                                                 |
#      |                                                                 unsigned char *
/usr/include/glib-2.0/glib/gstrfuncs.h:324:38: note: in definition of macro 'g_strdup'
#  324 | #define g_strdup(x) g_strdup_inline (x)
#      |                                      ^
/usr/include/glib-2.0/glib/gstrfuncs.h:309:30: note: expected 'const char *' but argument is of type 'unsigned char *'
#  309 | g_strdup_inline (const char *str)
#      |                  ~~~~~~~~~~~~^~~
#  244|                               {
#  245|                                   g_free(xkb->model_name);
#  246|->                                 xkb->model_name = g_strdup(prop + pos);
#  247|                               }
#  248|   

Error: COMPILER_WARNING (CWE-681): [#def58]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:254:58: warning[-Wpointer-sign]: pointer targets in passing argument 1 of 'strchr' differ in signedness
#  254 |                                 n_symbols = (strchr(prop + pos, ',') != NULL);
#      |                                                     ~~~~~^~~~~
#      |                                                          |
#      |                                                          unsigned char *
/usr/include/glib-2.0/glib/galloca.h:35: included_from: Included from here.
/usr/include/string.h:246:34: note: expected 'const char *' but argument is of type 'unsigned char *'
#  246 | extern char *strchr (const char *__s, int __c)
#      |                      ~~~~~~~~~~~~^~~
#  252|                                   gchar **symbols;
#  253|   
#  254|->                                 n_symbols = (strchr(prop + pos, ',') != NULL);
#  255|                                   symbols = g_strsplit(prop + pos, ",", XkbNumKbdGroups + 1);
#  256|   

Error: COMPILER_WARNING (CWE-681): [#def59]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:255:59: warning[-Wpointer-sign]: pointer targets in passing argument 1 of 'g_strsplit' differ in signedness
#  255 |                                 symbols = g_strsplit(prop + pos, ",", XkbNumKbdGroups + 1);
#      |                                                      ~~~~~^~~~~
#      |                                                           |
#      |                                                           unsigned char *
/usr/include/glib-2.0/glib/gstrfuncs.h:356:55: note: expected 'const gchar *' {aka 'const char *'} but argument is of type 'unsigned char *'
#  356 | gchar**               g_strsplit       (const gchar  *string,
#      |                                         ~~~~~~~~~~~~~~^~~~~~
#  253|   
#  254|                                   n_symbols = (strchr(prop + pos, ',') != NULL);
#  255|->                                 symbols = g_strsplit(prop + pos, ",", XkbNumKbdGroups + 1);
#  256|   
#  257|                                   for (i = 0; i < XkbNumKbdGroups; i++)

Error: COMPILER_WARNING (CWE-681): [#def60]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:273:59: warning[-Wpointer-sign]: pointer targets in passing argument 1 of 'strchr' differ in signedness
#  273 |                                 n_variants = (strchr(prop + pos, ',') != NULL);
#      |                                                      ~~~~~^~~~~
#      |                                                           |
#      |                                                           unsigned char *
/usr/include/string.h:246:34: note: expected 'const char *' but argument is of type 'unsigned char *'
#  246 | extern char *strchr (const char *__s, int __c)
#      |                      ~~~~~~~~~~~~^~~
#  271|                                   gchar **variants;
#  272|   
#  273|->                                 n_variants = (strchr(prop + pos, ',') != NULL);
#  274|                                   variants = g_strsplit(prop + pos, ",", XkbNumKbdGroups + 1);
#  275|   

Error: COMPILER_WARNING (CWE-681): [#def61]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:274:60: warning[-Wpointer-sign]: pointer targets in passing argument 1 of 'g_strsplit' differ in signedness
#  274 |                                 variants = g_strsplit(prop + pos, ",", XkbNumKbdGroups + 1);
#      |                                                       ~~~~~^~~~~
#      |                                                            |
#      |                                                            unsigned char *
/usr/include/glib-2.0/glib/gstrfuncs.h:356:55: note: expected 'const gchar *' {aka 'const char *'} but argument is of type 'unsigned char *'
#  356 | gchar**               g_strsplit       (const gchar  *string,
#      |                                         ~~~~~~~~~~~~~~^~~~~~
#  272|   
#  273|                                   n_variants = (strchr(prop + pos, ',') != NULL);
#  274|->                                 variants = g_strsplit(prop + pos, ",", XkbNumKbdGroups + 1);
#  275|   
#  276|                                   for (i = 0; i < XkbNumKbdGroups; i++)

Error: COMPILER_WARNING (CWE-681): [#def62]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:291:67: warning[-Wpointer-sign]: pointer targets in passing argument 1 of 'g_strdup_inline' differ in signedness
#  291 |                                 xkb->option_names = g_strdup(prop + pos);
#      |                                                              ~~~~~^~~~~
#      |                                                                   |
#      |                                                                   unsigned char *
/usr/include/glib-2.0/glib/gstrfuncs.h:324:38: note: in definition of macro 'g_strdup'
#  324 | #define g_strdup(x) g_strdup_inline (x)
#      |                                      ^
/usr/include/glib-2.0/glib/gstrfuncs.h:309:30: note: expected 'const char *' but argument is of type 'unsigned char *'
#  309 | g_strdup_inline (const char *str)
#      |                  ~~~~~~~~~~~~^~~
#  289|                               {
#  290|                                   g_free(xkb->option_names);
#  291|->                                 xkb->option_names = g_strdup(prop + pos);
#  292|                               }
#  293|   

Error: COMPILER_WARNING (CWE-681): [#def63]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:294:48: warning[-Wpointer-sign]: pointer targets in passing argument 1 of 'strlen' differ in signedness
#  294 |                             pos += strlen(prop + pos) + 1;
#      |                                           ~~~~~^~~~~
#      |                                                |
#      |                                                unsigned char *
/usr/include/string.h:407:35: note: expected 'const char *' but argument is of type 'unsigned char *'
#  407 | extern size_t strlen (const char *__s)
#      |                       ~~~~~~~~~~~~^~~
#  292|                               }
#  293|   
#  294|->                             pos += strlen(prop + pos) + 1;
#  295|                               substr++;
#  296|                           }

Error: CPPCHECK_WARNING (CWE-457): [#def64]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:299: warning[uninitvar]: Uninitialized variable: n_symbols
#  297|   
#  298|                           /* check for a valid variant list */
#  299|->                         if (n_symbols && !n_variants || !n_symbols && n_variants)
#  300|                           {
#  301|                               for (i = 0; i < XkbNumKbdGroups; i++)

Error: CPPCHECK_WARNING (CWE-457): [#def65]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:299: warning[uninitvar]: Uninitialized variable: n_variants
#  297|   
#  298|                           /* check for a valid variant list */
#  299|->                         if (n_symbols && !n_variants || !n_symbols && n_variants)
#  300|                           {
#  301|                               for (i = 0; i < XkbNumKbdGroups; i++)

Error: GCC_ANALYZER_WARNING (CWE-457): [#def66]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:299:29: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value 'n_symbols'
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:385:6: enter_function: entry to 'xkb_mechanism_constructor'
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:391:8: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:392:8: branch_true: ...to here
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:391:9: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:395:29: branch_true: ...to here
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:398:9: call_function: calling 'initialize_keyboard_description' from 'xkb_mechanism_constructor'
#  297|   
#  298|                           /* check for a valid variant list */
#  299|->                         if (n_symbols && !n_variants || !n_symbols && n_variants)
#  300|                           {
#  301|                               for (i = 0; i < XkbNumKbdGroups; i++)

Error: GCC_ANALYZER_WARNING (CWE-457): [#def67]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:299:29: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value 'n_variants'
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:385:6: enter_function: entry to 'xkb_mechanism_constructor'
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:391:8: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:392:8: branch_true: ...to here
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:391:9: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:395:29: branch_true: ...to here
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:398:9: call_function: calling 'initialize_keyboard_description' from 'xkb_mechanism_constructor'
#  297|   
#  298|                           /* check for a valid variant list */
#  299|->                         if (n_symbols && !n_variants || !n_symbols && n_variants)
#  300|                           {
#  301|                               for (i = 0; i < XkbNumKbdGroups; i++)

Error: COMPILER_WARNING (CWE-457): [#def68]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c: scope_hint: In function 'initialize_keyboard_description.isra.0'
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:299:29: warning[-Wmaybe-uninitialized]: 'n_symbols' may be used uninitialized
#  299 |                         if (n_symbols && !n_variants || !n_symbols && n_variants)
#      |                             ^~~~~~~~~
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:238:34: note: 'n_symbols' was declared here
#  238 |                         gboolean n_symbols, n_variants;
#      |                                  ^~~~~~~~~
#  297|   
#  298|                           /* check for a valid variant list */
#  299|->                         if (n_symbols && !n_variants || !n_symbols && n_variants)
#  300|                           {
#  301|                               for (i = 0; i < XkbNumKbdGroups; i++)

Error: COMPILER_WARNING (CWE-569): [#def69]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:299:39: warning[-Wparentheses]: suggest parentheses around '&&' within '||'
#  299 |                         if (n_symbols && !n_variants || !n_symbols && n_variants)
#      |                             ~~~~~~~~~~^~~~~~~~~~~~~~
#  297|   
#  298|                           /* check for a valid variant list */
#  299|->                         if (n_symbols && !n_variants || !n_symbols && n_variants)
#  300|                           {
#  301|                               for (i = 0; i < XkbNumKbdGroups; i++)

Error: COMPILER_WARNING (CWE-457): [#def70]
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:299:54: warning[-Wmaybe-uninitialized]: 'n_variants' may be used uninitialized
#  299 |                         if (n_symbols && !n_variants || !n_symbols && n_variants)
#      |                             ~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~
lxpanel-0.11.1/lxpanel/plugins/xkb/xkb.c:238:45: note: 'n_variants' was declared here
#  238 |                         gboolean n_symbols, n_variants;
#      |                                             ^~~~~~~~~~
#  297|   
#  298|                           /* check for a valid variant list */
#  299|->                         if (n_symbols && !n_variants || !n_symbols && n_variants)
#  300|                           {
#  301|                               for (i = 0; i < XkbNumKbdGroups; i++)

Error: GCC_ANALYZER_WARNING (CWE-688): [#def71]
lxpanel-0.11.1/lxpanel/src/conf.c:347:17: warning[-Wanalyzer-null-argument]: use of NULL 'f' where non-null expected
lxpanel-0.11.1/lxpanel/src/conf.c:396:8: enter_function: entry to 'config_setting_to_string'
lxpanel-0.11.1/lxpanel/src/conf.c:402:5: call_function: calling '_config_write_setting' from 'config_setting_to_string'
#  345|               }
#  346|               else
#  347|->                 fprintf(f, "%s%s {\n", buf->str, setting->name);
#  348|               g_string_append(buf, SETTING_INDENT);
#  349|               for (s = setting->first; s; s = s->next)

Error: COMPILER_WARNING: [#def72]
lxpanel-0.11.1/lxpanel/src/configurator.c: scope_hint: In function 'panel_configure'
lxpanel-0.11.1/lxpanel/src/configurator.c:1164:45: warning[-Wformat-truncation=]: '%d' directive output may be truncated writing between 1 and 10 bytes into a region of size 4
# 1164 |             snprintf(itext, sizeof(itext), "%d", i + 1);
#      |                                             ^~
lxpanel-0.11.1/lxpanel/src/configurator.c:1164:44: note: directive argument in the range [2, 2147483647]
# 1164 |             snprintf(itext, sizeof(itext), "%d", i + 1);
#      |                                            ^~~~
/usr/include/bits/stdio2.h:68:10: note: '__snprintf_chk' output between 2 and 11 bytes into a destination of size 4
#   68 |   return __builtin___snprintf_chk (__s, __n, __USE_FORTIFY_LEVEL - 1,
#      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#   69 |                                    __glibc_objsize (__s), __fmt,
#      |                                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#   70 |                                    __va_arg_pack ());
#      |                                    ~~~~~~~~~~~~~~~~~
# 1162|           for (i = 1; i < monitors; i++)
# 1163|           {
# 1164|->             snprintf(itext, sizeof(itext), "%d", i + 1);
# 1165|   #if GTK_CHECK_VERSION(3, 0, 0)
# 1166|               gtk_list_store_append(model, &it);

Error: GCC_ANALYZER_WARNING (CWE-457): [#def73]
lxpanel-0.11.1/lxpanel/src/icon-grid.c:240:25: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value 'x'
lxpanel-0.11.1/lxpanel/src/icon-grid.c:207:8: branch_false: following 'false' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:214:20: branch_false: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:221:30: branch_true: following 'true' branch (when 'ige' is non-NULL)...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:223:9: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:224:12: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:227:13: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:233:16: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:236:21: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:236:20: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:239:24: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:240:41: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:240:25: danger: use of uninitialized value 'x' here
#  238|                       y = y_border;
#  239|                       if (direction == GTK_TEXT_DIR_RTL)
#  240|->                         x -= (x_delta + ig->spacing);
#  241|                       else
#  242|                           x += (x_delta + ig->spacing);

Error: GCC_ANALYZER_WARNING (CWE-457): [#def74]
lxpanel-0.11.1/lxpanel/src/icon-grid.c:242:25: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value 'x'
lxpanel-0.11.1/lxpanel/src/icon-grid.c:207:8: branch_false: following 'false' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:214:20: branch_false: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:221:30: branch_true: following 'true' branch (when 'ige' is non-NULL)...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:223:9: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:224:12: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:227:13: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:233:16: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:236:21: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:236:20: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:239:24: branch_false: following 'false' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:242:41: branch_false: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:242:25: danger: use of uninitialized value 'x' here
#  240|                           x -= (x_delta + ig->spacing);
#  241|                       else
#  242|->                         x += (x_delta + ig->spacing);
#  243|                       x_delta = 0;
#  244|                       // FIXME: if fill_width and rows = 1 then allocate whole column

Error: GCC_ANALYZER_WARNING (CWE-457): [#def75]
lxpanel-0.11.1/lxpanel/src/icon-grid.c:273:38: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value 'x'
lxpanel-0.11.1/lxpanel/src/icon-grid.c:207:8: branch_false: following 'false' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:214:20: branch_false: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:221:30: branch_true: following 'true' branch (when 'ige' is non-NULL)...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:223:9: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:224:12: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:227:13: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:233:16: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:236:21: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:272:16: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:273:42: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:273:38: danger: use of uninitialized value 'x' here
#  271|               }
#  272|               if (direction == GTK_TEXT_DIR_RTL)
#  273|->                 child_allocation.x = x - child_allocation.width;
#  274|               else
#  275|                   child_allocation.x = x;

Error: COMPILER_WARNING (CWE-457): [#def76]
lxpanel-0.11.1/lxpanel/src/icon-grid.c: scope_hint: In function 'panel_icon_grid_size_allocate'
lxpanel-0.11.1/lxpanel/src/icon-grid.c:273:40: warning[-Wmaybe-uninitialized]: 'x' may be used uninitialized
#  273 |                 child_allocation.x = x - child_allocation.width;
#      |                                      ~~^~~~~~~~~~~~~~~~~~~~~~~~
lxpanel-0.11.1/lxpanel/src/icon-grid.c:123:11: note: 'x' was declared here
#  123 |     guint x, y;
#      |           ^
#  271|               }
#  272|               if (direction == GTK_TEXT_DIR_RTL)
#  273|->                 child_allocation.x = x - child_allocation.width;
#  274|               else
#  275|                   child_allocation.x = x;

Error: GCC_ANALYZER_WARNING (CWE-457): [#def77]
lxpanel-0.11.1/lxpanel/src/icon-grid.c:275:17: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value 'x'
lxpanel-0.11.1/lxpanel/src/icon-grid.c:207:8: branch_false: following 'false' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:214:20: branch_false: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:221:30: branch_true: following 'true' branch (when 'ige' is non-NULL)...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:223:9: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:224:12: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:227:13: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:233:16: branch_true: following 'true' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:236:21: branch_true: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:272:16: branch_false: following 'false' branch...
lxpanel-0.11.1/lxpanel/src/icon-grid.c:275:17: branch_false: ...to here
lxpanel-0.11.1/lxpanel/src/icon-grid.c:275:17: danger: use of uninitialized value 'x' here
#  273|                   child_allocation.x = x - child_allocation.width;
#  274|               else
#  275|->                 child_allocation.x = x;
#  276|               if (req.height < child_height - 1)
#  277|                   y += (child_height - req.height) / 2;

Error: CPPCHECK_WARNING (CWE-476): [#def78]
lxpanel-0.11.1/lxpanel/src/misc.c:1368: error[ctunullpointer]: Null pointer dereference: panel
# 1366|       const gchar * image_file, int width, int height, gulong highlight_color, gboolean keep_ratio, Panel * panel, const gchar * label)
# 1367|   {
# 1368|->     return _lxpanel_button_new_for_icon(panel->topgwin, fm_icon_from_name(image_file), height, highlight_color, label);
# 1369|   }
# 1370|   

Error: CPPCHECK_WARNING (CWE-476): [#def79]
lxpanel-0.11.1/lxpanel/src/misc.c:1368: warning[nullPointer]: Possible null pointer dereference: panel
# 1366|       const gchar * image_file, int width, int height, gulong highlight_color, gboolean keep_ratio, Panel * panel, const gchar * label)
# 1367|   {
# 1368|->     return _lxpanel_button_new_for_icon(panel->topgwin, fm_icon_from_name(image_file), height, highlight_color, label);
# 1369|   }
# 1370|   

Error: GCC_ANALYZER_WARNING (CWE-476): [#def80]
lxpanel-0.11.1/lxpanel/src/misc.c:1368:12: warning[-Wanalyzer-null-dereference]: dereference of NULL 'panel'
lxpanel-0.11.1/lxpanel/src/misc.c:1358:13: enter_function: entry to 'fb_button_new_from_file'
lxpanel-0.11.1/lxpanel/src/misc.c:1361:12: call_function: calling 'fb_button_new_from_file_with_label' from 'fb_button_new_from_file'
# 1366|       const gchar * image_file, int width, int height, gulong highlight_color, gboolean keep_ratio, Panel * panel, const gchar * label)
# 1367|   {
# 1368|->     return _lxpanel_button_new_for_icon(panel->topgwin, fm_icon_from_name(image_file), height, highlight_color, label);
# 1369|   }
# 1370|   

Error: COMPILER_WARNING (CWE-1164): [#def81]
lxpanel-0.11.1/lxpanel/src/panel.c:243:17: warning[-Wunused-function]: 'lxpanel_has_plugin' defined but not used
#  243 | static gboolean lxpanel_has_plugin (LXPanel *panel, const char *name)
#      |                 ^~~~~~~~~~~~~~~~~~
#  241|   }
#  242|   
#  243|-> static gboolean lxpanel_has_plugin (LXPanel *panel, const char *name)
#  244|   {
#  245|       gboolean found = FALSE;

Error: COMPILER_WARNING (CWE-563): [#def82]
lxpanel-0.11.1/lxpanel/src/plugin.c: scope_hint: In function '_old_plugin_config'
lxpanel-0.11.1/lxpanel/src/plugin.c:72:30: warning[-Wunused-variable]: unused variable 'init'
#   72 |     const LXPanelPluginInit *init = PLUGIN_CLASS(instance);
#      |                              ^~~~
#   70|   static GtkWidget *_old_plugin_config(LXPanel *panel, GtkWidget *instance)
#   71|   {
#   72|->     const LXPanelPluginInit *init = PLUGIN_CLASS(instance);
#   73|       Plugin * plugin;
#   74|   

Error: COMPILER_WARNING (CWE-563): [#def83]
lxpanel-0.11.1/lxpanel/src/plugin.c: scope_hint: In function '_old_plugin_reconfigure'
lxpanel-0.11.1/lxpanel/src/plugin.c:84:30: warning[-Wunused-variable]: unused variable 'init'
#   84 |     const LXPanelPluginInit *init = PLUGIN_CLASS(instance);
#      |                              ^~~~
#   82|   static void _old_plugin_reconfigure(LXPanel *panel, GtkWidget *instance)
#   83|   {
#   84|->     const LXPanelPluginInit *init = PLUGIN_CLASS(instance);
#   85|       Plugin * plugin;
#   86|   

Scan Properties

analyzer-version-clippy1.86.0
analyzer-version-cppcheck2.17.1
analyzer-version-gcc15.0.1
analyzer-version-gcc-analyzer15.0.1
analyzer-version-shellcheck0.10.0
analyzer-version-unicontrol0.0.2
enabled-pluginsclippy, cppcheck, gcc, shellcheck, unicontrol
exit-code0
hostip-172-16-1-217.us-west-2.compute.internal
known-false-positives/usr/share/csmock/known-false-positives.js
known-false-positives-rpmknown-false-positives-0.0.0.20250425.124705.g1c7c448.main-1.el9.noarch
mock-configfedora-rawhide-x86_64
project-namelxpanel-0.11.1-1.fc43
store-results-to/tmp/tmplszh1nkc/lxpanel-0.11.1-1.fc43.tar.xz
time-created2025-04-25 14:36:13
time-finished2025-04-25 14:38:39
toolcsmock
tool-args'/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'unicontrol,cppcheck,gcc,clippy,shellcheck' '-o' '/tmp/tmplszh1nkc/lxpanel-0.11.1-1.fc43.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmplszh1nkc/lxpanel-0.11.1-1.fc43.src.rpm'
tool-versioncsmock-3.8.1.20250422.172604.g26bc3d6-1.el9