Text  |   XML   |   Visible Warnings:

Irssi : Irssi analysis 1 : Null Pointer Dereference  at nicklist.c:82

Categories: LANG.MEM.NPD CWE:476
Warning ID: 2174.2179
Procedure: nicklist_insert
Trace: View
Modified: Wed Sep 2 11:51:45 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/core/irc-nicklist.c
   Enter irc_nicklist_insert
 33 NICK_REC *irc_nicklist_insert(IRC_CHANNEL_REC *channel, const char *nick,
 34                               int op, int halfop, int voice, int send_massjoin) 
 35 {
 36         NICK_REC *rec;
 37  
 38         g_return_val_if_fail(IS_IRC_CHANNEL(channel), NULL);
 39         g_return_val_if_fail(nick != NULL, NULL);
 40  
 41         rec = g_new0(NICK_REC, 1);
 42         rec->nick = g_strdup(nick);
 43  
 44         if (op) rec->op = TRUE;
 45         if (halfop) rec->halfop = TRUE;
 46         if (voice) rec->voice = TRUE;
 47         rec->send_massjoin = send_massjoin;
 48  
true49         nicklist_insert(CHANNEL(channel), rec);
     /u1/paul/SATE/2010/c/irssi/irssi-0.8.14/src/core/nicklist.c
     Enter irc_nicklist_insert / nicklist_insert
$param_1 <= 409577   void nicklist_insert(CHANNEL_REC *channel, NICK_REC *nick) 
 78   {
 79           /*MODULE_DATA_INIT(nick);*/ 
 80    
 81           nick->type = module_get_uniq_id("NICK", 0);   /* Null Pointer Dereference (ID: 2301.2310) */
channel <= 409582           nick->chat_type = channel->chat_type;     /* Null Pointer Dereference */  /* Null Pointer Dereference (ID: 2302.2311) */
     Exit irc_nicklist_insert / nicklist_insert
Preconditions
$param_2 != 0
$param_3 != 0
$param_4 != 0
$param_5 != 0
&$unknown_413143 = 0
Postconditions
_g_boolean_var_' = 1
_g_boolean_var_' = 1
((char*)&$unknown_413142)[44]' = $param_6
((char*)&$unknown_413142)[44]' = 1
((char*)&$unknown_413142)[44]' = 1
((char*)&$unknown_413142)[44]' = 1
channel' = $param_1
channel' = 0
halfop' = $param_4
nick' = $param_2
nick' = &$unknown_413142
op' = $param_3
rec' = &$unknown_413142
send_massjoin' = $param_6
voice' = $param_5




Change Warning 2174.2179 : Null Pointer Dereference

Priority:
State:
Finding:
Owner:
Note: