This is the mail archive of the gdb@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: alloca is bad?


Fernando Nasser wrote:

> That takes care of the CLI commands.  (MI and Insight are probably broken)
> 
> Any other interpreter that uses the libgdb exported functions instead
> of the CLI execute_command will have to do the same.  How can we control
> that this is done if a script, for instance, calls random libgdb functions?
> 
> Maybe we will have to add a call to alloca(0) to every libgdb call.

I'd argue that the analysis of this error demonstrates that people are
going to forget to call alloca(0).  It is after all an obscure querk of
libiberty and not exactly a normal C convention.

Based on that, inserting an alloca(0) call in every libgdb function
probably is best :-(

	enjoy,
		Andrew

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]