This is the mail archive of the gdb-patches@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: [PATCH RFA] mi/mi-main.c: Don't use variable-length array extension


> These are probably obvious fixes, but I used alloca() which is
> sometimes considered objectionable, so I decided to ask for approval. 
> I'm willing to rework the patch to use xmalloc(), make_cleanup(), etc,
> but it will be messier.
> 
> 	* mi-main.c (register_changed_p, get_register): Use alloca()
> 	to allocate space previously allocated via gcc's
> 	variable-length array extension.


This is one of the uses of alloca that everyone has grown accustomed to.

	Andrew


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