pidgin/purple-plugin-pack

Hopefully fix #381 by checking for NULL in a couple places.
org.guifications.plugins
2008-08-03, rekkanoryo
8d299a901c8d
Parents fe283e690879
Children 4f8f5a18fb94
Hopefully fix #381 by checking for NULL in a couple places.
  • +4 -2
    snpp/snpp.c
  • --- a/snpp/snpp.c Sun Aug 03 08:01:40 2008 -0400
    +++ b/snpp/snpp.c Sun Aug 03 08:08:50 2008 -0400
    @@ -111,10 +111,12 @@
    static void snpp_reset(PurpleConnection *gc, struct snpp_data *sd)
    {
    purple_debug_info("snpp", "snpp_reset\n");
    - if (gc->inpa)
    +
    + if (gc && gc->inpa)
    purple_input_remove(gc->inpa);
    - close(sd->fd);
    + if (sd && sd->fd)
    + close(sd->fd);
    if (sd->current_page != NULL)
    snpp_page_destroy(sd->current_page);