Text  |   XML   |   Visible Warnings:

Irssi : Irssi analysis 1 : Dangerous Function Cast  at flood.c:304

Categories: LANG.CAST.FN CWE:628 CWE:234
Warning ID: 654.654
Procedure: read_settings
Trace: View
Modified: Wed Sep 2 11:35:55 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
   /u1/paul/SATE/2010/c/irssi/irssi-0.8.14/src/irc/flood/flood.c
   Enter read_settings
 294  
 295 static void read_settings(void) 
 296 {
 297         flood_timecheck = settings_get_int("flood_timecheck");
 298         flood_max_msgs = settings_get_int("flood_max_msgs");
 299  
 300         if (flood_timecheck > 0 && flood_max_msgs > 0) {
 301                 if (flood_tag == -1) {
 302                         flood_tag = g_timeout_add(5000, (GSourceFunc) flood_timeout, NULL);   /* Dangerous Function Cast (ID: 652.652) */
 303  
Wrong Number of Parameters304                         signal_add("event privmsg", (SIGNAL_FUNC) flood_privmsg);     /* Dangerous Function Cast */
 305                         signal_add("event notice", (SIGNAL_FUNC) flood_notice);   /* Dangerous Function Cast (ID: 655.655) */
 306                         signal_add("ctcp msg", (SIGNAL_FUNC) flood_ctcp);   /* Dangerous Function Cast (ID: 656.656) */
 307                 }
 308         } else if (flood_tag != -1) {
 309                 g_source_remove(flood_tag);
 310                 flood_tag = -1;
 311  
 312                 signal_remove("event privmsg", (SIGNAL_FUNC) flood_privmsg);   /* Dangerous Function Cast (ID: 657.657) */
 313                 signal_remove("event notice", (SIGNAL_FUNC) flood_notice);   /* Dangerous Function Cast (ID: 658.658) */
 314                 signal_remove("ctcp msg", (SIGNAL_FUNC) flood_ctcp);   /* Dangerous Function Cast (ID: 653.653) */




Change Warning 654.654 : Dangerous Function Cast

Priority:
State:
Finding:
Owner:
Note: