[exim] Signal 11 in local_scan()

Startseite
Nachricht löschen
Nachricht beantworten
Autor: Jack Bailey
Datum:  
To: exim users
Betreff: [exim] Signal 11 in local_scan()
Hello,

I've written a local_scan function for exim-4.61 in which I'm trying to
test sender_address. The manual says:

*uschar *sender_address*

    The envelope sender address. For bounce messages this is the empty
    string.



local_scan.c:

#define ISNULL(s) (s == NULL || *s == '\0')

[snip]

        if(ISNULL(sender_address)) {
                smtp_printf("250 2.0.0 Message accepted\r\n");
                return(0);
        }


When this code is executed:

local_scan() function crashed with signal 11

It's been my impression the empty string is "", but testing for it here
is the cause of the SIGSEGV. On bounces sender_address is NULL.

Also, I find it interesting the code generated by gcc is testing for *s
== '\0' when s == NULL is true.

Jack