<<< Date Index >>>     <<< Thread Index >>>

Re: Mutt recursion crash with account hooks



On Monday, 12 January 2009 at 11:26, Brendan Cully wrote:
> On Monday, 12 January 2009 at 13:15, Kyle Wheeler wrote:
> > With recent changes to the mutt source, an infinite recursive loop has  
> > been created in some configuration scenarios. Specifically, if you have 
> > account-hooks to set your $folder and then attempt to set your $folder. 
> > For example:
> >
> >     account-hook 'me@server' \
> >         'set folder="imaps://me@server/INBOX";\
> >          set spoolfile="imaps://me@server/INBOX"'
> >
> >     set folder=imaps://me@server/INBOX
> >
> > What will happen is that while parsing the “set folder” line, mutt will 
> > attempt to expand the path specified, which now requires triggering the 
> > account-hooks. The account hook will attempt to expand the path specified, 
> > which will re-trigger the account hook, which will re-attempt expanding 
> > the path specified, and this will continue recursing until the stack is 
> > thoroughly smashed.
> 
> Oops. I'll add a guard for this. Thanks for finding it :)

Should be fixed in 10e224e86f0b. Thanks again for spotting.