Re: [PATCH] PR libstdc++/87228 Use heap for large buffers instead of alloca

2018-09-05 Thread Jonathan Wakely
On 05/09/18 15:32 +0100, Jonathan Wakely wrote: Using a huge width in a formatted output operation results in stack overflow due to no restriction on the size passed to alloca. This patch causes the formatting functions to use the heap instead of the stack when a large buffer is needed.

[PATCH] PR libstdc++/87228 Use heap for large buffers instead of alloca

2018-09-05 Thread Jonathan Wakely
Using a huge width in a formatted output operation results in stack overflow due to no restriction on the size passed to alloca. This patch causes the formatting functions to use the heap instead of the stack when a large buffer is needed. PR libstdc++/87228 * include/bits/locale_