I've got this one fixed in my tree, will commit in a few hours. Still
working out another problem that occurs a little bit after this one
(which you might hit if you're using the changes below).

On Sun, 2006-02-19 at 02:46 +0300, Oleg Lapshin wrote:

> 3rd:
> 
> Part of log:
> dbmail-message.c,dbmail_message_cache_subjectfield: no subject field value 
> [23536]
> pipe.c, insert_messages: temporary msgidnr is [49552]
> pipe.c, insert_messages: calling sort_and_deliver for useridnr [2]
> misc.c, find_bounded: Found nothing between '+' and '@'
> dbmysql.c,db_query: executing query [SELECT name from dbmail_sievescripts 
> where owner_idnr = 2 and active = 1]
> serverchild.c,active_child_sig_handler: got signal [Segmentation fault]
> serverchild.c,active_child_sig_handler: cannot ignore this. Terminating
> 
> In this situation I have 2 scripts in table, but all of them have active=0
> If I have one of them active, then all ok.
> If I have no scripts at all - Segmentation fault
> 
> Now, I am doing this in db.c (in db_get_sievescript_active):
> 
>         n = db_num_rows();
>         if (n > 0) {
>                 *scriptname = dm_strdup(db_get_result(0, 0));
> +                n=DM_SUCCESS;
> +        } else {
> +                n=DM_EQUERY;
>         }
> 
>         db_free_result();
> -        return DM_SUCCESS;
> +        return n;
> }
> 
> and it's OK
> 
> (sorry, but I am not professional C-programmer)
> 


Reply via email to