Mercurial > pidgin.yaz
comparison src/away.c @ 8820:86944ae7c033
[gaim-migrate @ 9582]
uninitialized variables are not cool
committer: Tailor Script <tailor@pidgin.im>
author | Nathan Walp <nwalp@pidgin.im> |
---|---|
date | Mon, 26 Apr 2004 16:35:52 +0000 |
parents | 482fc53c969d |
children | 269f576d61ac |
comparison
equal
deleted
inserted
replaced
8819:d7ed3a4bdf35 | 8820:86944ae7c033 |
---|---|
285 serv_set_away_all(awaymessage->message); | 285 serv_set_away_all(awaymessage->message); |
286 } | 286 } |
287 | 287 |
288 void do_rem_away_mess(gchar *name) | 288 void do_rem_away_mess(gchar *name) |
289 { | 289 { |
290 struct away_message *a; | 290 struct away_message *a = NULL; |
291 struct away_message *default_away = NULL; | 291 struct away_message *default_away = NULL; |
292 const char *default_away_name; | 292 const char *default_away_name; |
293 GSList *l; | 293 GSList *l; |
294 | 294 |
295 /* Lookup the away message based on the title */ | 295 /* Lookup the away message based on the title */ |
298 if (!strcmp(a->name, name)) | 298 if (!strcmp(a->name, name)) |
299 break; | 299 break; |
300 } | 300 } |
301 g_free(name); | 301 g_free(name); |
302 | 302 |
303 if (l == NULL) { | 303 if (l == NULL || a == NULL) { |
304 /* Could not find away message! */ | 304 /* Could not find away message! */ |
305 return; | 305 return; |
306 } | 306 } |
307 | 307 |
308 default_away_name = gaim_prefs_get_string("/core/away/default_message"); | 308 default_away_name = gaim_prefs_get_string("/core/away/default_message"); |