src/parse.c
changeset 45 535478a0f482
parent 40 5b7e8dba46a0
child 48 34094173351c
equal deleted inserted replaced
44:f08e8fb2c1da 45:535478a0f482
    78 
    78 
    79     time_t t;
    79     time_t t;
    80     struct tm *timeptr;
    80     struct tm *timeptr;
    81 
    81 
    82     /*
    82     /*
       
    83      * make sure that parseable data is available
       
    84      * this prevents a possible segmentation fault
       
    85      */
       
    86     if (message->user == NULL)
       
    87         message->user = "error";
       
    88     if (message->email == NULL)
       
    89         message->email = "server.err";
       
    90 
       
    91     /*
    83      * default message
    92      * default message
    84      */
    93      */
    85     snprintf (msg, sizeof (msg), "PRIVMSG %s :%s.\r\n", message->channel, gettext ("Request cannot be performed"));
    94     snprintf (msg, sizeof (msg), "PRIVMSG %s :%s.\r\n", message->channel, gettext ("Request cannot be performed"));
    86 
    95 
    87     /*
    96     /*