bug-mailutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug-mailutils] Re: crash on invalid config file


From: Simon Josefsson
Subject: [bug-mailutils] Re: crash on invalid config file
Date: Thu, 24 Sep 2009 16:15:33 +0200
User-agent: Gnus/5.110011 (No Gnus v0.11) Emacs/23.1 (gnu/linux)

Sergey Poznyakoff <address@hidden> writes:

> Hi Simon,
>
>> Hi, I noticed this crash when using an invalid configuration file:
>> 
>> address@hidden:~/src/mailutils/imap4d master$ cat 
>> /home/jas/src/www-gsasl/test-server/imap4d.rc server {
>>   transcript true;
>> }
>
> Thanks! Here's the fix:
>
> diff --git a/mailbox/msrv.c b/mailbox/msrv.c
> index a318371..13a85d4 100644
> --- a/mailbox/msrv.c
> +++ b/mailbox/msrv.c
> @@ -970,7 +970,7 @@ server_section_parser (enum mu_cfg_section_stage stage,
>      {
>      case mu_cfg_section_start:
>        {
> -     if (node->label->type != MU_CFG_STRING)
> +     if (node->label == NULL || node->label->type != MU_CFG_STRING)
>         return 1;
>       /* FIXME: should not modify 2nd arg, or it should not be const */
>       return server_block_begin (tree->debug, node->label->v.string,

Thanks!

/Simon




reply via email to

[Prev in Thread] Current Thread [Next in Thread]