bug-m4
[Top][All Lists]
Advanced

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

Re: possible infinite loop in m4


From: Mike Frysinger
Subject: Re: possible infinite loop in m4
Date: Tue, 6 Jul 2010 00:21:26 -0400
User-agent: KMail/1.13.1 (Linux/2.6.34; KDE/4.4.4; x86_64; ; )

On Tuesday, July 06, 2010 00:13:55 Eric Blake wrote:
> ----- "Mike Frysinger" <address@hidden> wrote:
> > i believe a recent autoconf update triggered a bug in m4 while
> > processing
> > crappy m4 code.  the project in question is "rezound":
> > http://rezound.sf.net/ (version 0.12.3_beta to be exact)
> > 
> > the reduced test case is:
> > $ cat configure.ac
> > AC_INIT
> > ajv_CXX_FLAG(-g)
> > AC_OUTPUT
> > $ cat aclocal.m4
> > AC_DEFUN(ajv_CXX_FLAG,
> > 
> >     [AC_MSG_CHECKING(if $CXX accepts $1 )]
> >     AC_MSG_RESULT(yes)
> > 
> > )
> > $ autoconf
> > <hang here in m4>
> 
> That's a bug in the user's configure.ac script for not quoting things
> correctly in the first place.  Autoconf can't work around every
> piece of bad code thrown at it, and my recommendation would
> be to fix rezound rather than trying to throw more workarounds in
> autoconf to avoid this bad code at the expense of penalizing
> performance on good code.

i agree rezound has crappy code (i made suggestions for throwing out the whole 
thing for something better), but i think m4 should be smarter about infinite 
loops.  this could just as easily been a typo and about the only way to track 
it down is to literally start commenting out things in the source until it 
stops looping forever.  that's a poor development environment imo.
-mike

Attachment: signature.asc
Description: This is a digitally signed message part.


reply via email to

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