Text  |   XML   |   Visible Warnings:

irssi-0.8.14 : irssi-0.8.14 analysis 2 : Dangerous Function Cast  at keyboard.c:363

Categories: LANG.CAST.FN CWE:628 CWE:234
Warning ID: 2065.27228
Procedure: key_states_rescan
Trace: view
Modified: Thu Nov 26 11:01:53 2009   show details
 
Priority: None
State: None
Finding: None
Owner: None
  edit properties

Legend [ X ]
Warning Location
Contributes
Parse Error
Other Warning
Two or More Loop Iterations
On Execution Path
Comment
Macro
Preprocessor
Include
Keyword
Preprocessed Away

Source  |  Language: C Hide Legend     
ProblemLineSource
   /kat0/fletcher/SATE/2010/irssi-0.8.14/src/fe-common/core/keyboard.c
   Enter key_states_rescan
 353  
 354 /* Rescan all the key combos and figure out which characters are supposed 
 355    to be treated as characters and which as key combos.
 356    Yes, this is pretty slow function... */ 
 357 static void key_states_rescan(void) 
 358 {
 359         GString *temp;
 360  
 361         memset(used_keys, 0, sizeof(used_keys));
 362  
Wrong Number of Parameters363         g_tree_traverse(key_states, (GTraverseFunc) key_state_destroy,     /* Dangerous Function Cast */
 364                         G_IN_ORDER, NULL);
 365         g_tree_destroy(key_states);
 366         key_states = g_tree_new((GCompareFunc) strcmp);
 367  
 368         temp = g_string_new(NULL);
 369         g_hash_table_foreach(keys, (GHFunc) key_states_scan_key, temp);   /* Dangerous Function Cast (ID: 2067.27229) */
 370         g_string_free(temp, TRUE);
 371 } 
 372  
 373 void key_configure_freeze(void)




Change Warning 2065.27228 : Dangerous Function Cast

Priority:
State:
Finding:
Owner:
Note: