On Wed, Jul 06, 2005 at 02:34:04PM +0300, Kostas Zorbadelos wrote:
> On Tue, Jul 05, 2005 at 02:33:37PM +0300, Sergey Poznyakoff wrote:
> > Sergey Poznyakoff <[EMAIL PROTECTED]> wrote:
> >
> > > It should be easy to fix, I'll get back to you later on
> > > this subject.
> >
> > Here it goes:
> >
>
> Sergey your patch works as expected.
> Thanks!
>
Sergey, after recompiling the mailutils snapshot with your patch
another error was introduced:
libsieve and the sieve executable (with -L flag) cannot find the
vacation action. The library vacation.so exists in the installed
location (/usr/local/mailutils/lib/mailutils) however I get the error
filters.sieve:1: source for the required action vacation is not available
filters.sieve:5: unknown action: vacation
I include my filters.sieve file that has the searchpath directive.
Really weird! Any ideas about what is going wrong here?
> > Index: libsieve/actions.c
> > ===================================================================
> > RCS file: /cvsroot/mailutils/mailutils/libsieve/actions.c,v
> > retrieving revision 1.25
> > diff -p -u -r1.25 actions.c
> > --- libsieve/actions.c 17 May 2005 13:13:36 -0000 1.25
> > +++ libsieve/actions.c 5 Jul 2005 11:30:09 -0000
> > @@ -113,14 +113,23 @@ sieve_get_message_sender (message_t msg,
> > return rc;
> >
> > rc = envelope_sender (envelope, NULL, 0, &size);
> > - if (rc)
> > - return rc;
> > + if (rc == 0)
> > + {
> > + if (!(text = malloc (size + 1)))
> > + return ENOMEM;
> > + envelope_sender (envelope, text, size + 1, NULL);
> > + }
> > + else
> > + {
> > + header_t hdr = NULL;
> > + message_get_header (msg, &hdr);
> > + if (rc = header_aget_value (hdr, MU_HEADER_SENDER, &text))
> > + rc = header_aget_value (hdr, MU_HEADER_FROM, &text);
> > + }
> >
> > - if (!(text = malloc (size + 1)))
> > - return ENOMEM;
> > - envelope_sender (envelope, text, size + 1, NULL);
> > - *ptext = text;
> > - return 0;
> > + if (rc == 0)
> > + *ptext = text;
> > + return rc;
> > }
> >
> > static int
> >
> > Regards,
> > Sergey
> >
--
Kostas Zorbadelos
Systems Designer/Developer, Otenet SA
[EMAIL PROTECTED] contact: kzorba (at) otenet.gr
Out there in the darkness, out there in the night
out there in the starlight, one soul burns brighter
than a thousand suns.
#searchpath "/usr/local/mailutils/lib/mailutils"
require ["fileinto","redirect","vacation","reject"];
if header :contains "from" "[EMAIL PROTECTED]"
{
vacation "Sorry I am unavailable now...";
}
if header :contains "from" "smaraf"
{
redirect "[EMAIL PROTECTED]";
}
if header :contains "from" "Tavernarakis"
{
redirect "[EMAIL PROTECTED]";
}
_______________________________________________
Bug-mailutils mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-mailutils