Text   |  XML   |  ReML   |   Visible Warnings:

Null Pointer Dereference  at prefs.c:1367

No properties have been set. | edit properties
Jump to warning location ↓ warning details...
Show Events | Options

recent_read_profile_static

(/home/sate/Testcases/c/cve/wireshark-1.2.0/gtk/recent.c)expand/collapse
Show more  
 802  recent_read_profile_static(char **rf_path_return, int *rf_errno_return)
 803  {
 804    char       *rf_path, *rf_common_path;
 805    FILE       *rf;
 806   
 807    /* set defaults */
 808    recent.main_toolbar_show      = TRUE;
 809    recent.filter_toolbar_show    = TRUE;
 810    recent.airpcap_toolbar_show   = FALSE;
 811    recent.airpcap_driver_check_show   = TRUE;
 812    recent.packet_list_show       = TRUE;
 813    recent.tree_view_show         = TRUE;
 814    recent.byte_view_show         = TRUE;
 815    recent.statusbar_show         = TRUE;
 816    recent.packet_list_colorize   = TRUE;
 817    recent.gui_time_format        = TS_RELATIVE;
 818    recent.gui_time_precision     = TS_PREC_AUTO;
 819    recent.gui_zoom_level         = 0;
 820   
 821    /* pane size of zero will autodetect */
 822    recent.gui_geometry_main_upper_pane   = 0;
 823    recent.gui_geometry_main_lower_pane   = 0;
 824   
 825    recent.has_gui_geometry_main_upper_pane = TRUE;
 826    recent.has_gui_geometry_main_lower_pane = TRUE;
 827    recent.has_gui_geometry_status_pane = TRUE;
 828   
 829    if (recent.col_width_list) {
 830      free_col_width_info(&recent);
 831    }
 832   
 833    /* Construct the pathname of the user's recent file. */
 834    rf_path = get_persconffile_path(RECENT_FILE_NAME, TRUE, FALSE);
 835   
 836    /* Read the user's recent file, if it exists. */
 837    *rf_path_return = NULL;
 838    if ((rf = ws_fopen(rf_path, "r")) != NULL) {
 839      /* We succeeded in opening it; read it. */
 840      read_prefs_file(rf_path, rf, read_set_recent_pair_static, NULL);
 841      fclose(rf);
 842      rf_common_path = get_persconffile_path(RECENT_COMMON_FILE_NAME, FALSE, FALSE);
 843[+]     if (!file_exists(rf_common_path)) {
 844        /* Read older common settings from recent file */
 845        rf = ws_fopen(rf_path, "r");
 846[+]       read_prefs_file(rf_path, rf, read_set_recent_common_pair_static, NULL);
expand/collapse

read_prefs_file

(/home/sate/Testcases/c/cve/wireshark-1.2.0/epan/prefs.c)expand/collapse
Show more  
 1354  read_prefs_file(const char *pf_path, FILE *pf, pref_set_pair_cb pref_set_pair_fct, void *private_data)
 1355  {
 1356    enum { START, IN_VAR, PRE_VAL, IN_VAL, IN_SKIP };
 1357    int       got_c, state = START;
 1358    GString  *cur_val;
 1359    GString  *cur_var;
 1360    gboolean  got_val = FALSE;
 1361    gint      fline = 1, pline = 1;
 1362    gchar     hint[] = "(applying your preferences once should remove this warning)";
 1363   
 1364    cur_val = g_string_new("");
 1365    cur_var = g_string_new("");
 1366   
 1367    while ((got_c = getc(pf)) != EOF) {
Show more  
Show more  




Change Warning 4152.30361 : Null Pointer Dereference

Priority:
State:
Finding:
Owner:
Note: