Ticket #529 (Open)Wed Oct 27 16:58:21 UTC 2021
DDE tools fail with long command lines
Reported by: | Stuart Swales (8827) | Severity: | Normal |
Part: | RISC OS: Software library | Release: | |
Milestone: | Status | Open |
Details by Stuart Swales (8827):
The default RootStackSize in the SCL seems somewhat small (4096b) for applications. <code>kernel_init</code> copies in the command line from <code>SWI DDEUtils_GetCL</code> having first read its size with <code>SWI DDEUtilsGetCLSize</code> but not actually checking whether there is enough space for it. A corrupt stack results shortly thereafter… Either trap in trap handler or no space for stack, YMMV.
Changelog:
Modified by Stuart Swales (8827) Wed, October 27 2021 - 16:59:25 GMT
- Attachment added: Makefile
Just drag the attached Makefile to Amu to watch cc barf.
Modified by Sprow (202) Sun, March 06 2022 - 18:11:00 GMT
- Part changed from RISC OS: C/C++ toolchain to RISC OS: Software library
Having looked at kernel_init I think it should be possible to move the setting of O_allocProc/O_freeProc and friends up (since they don’t need to see the command line) which would then allow a stack extension if DDEUtilsGetCLSize wants more than 4k.
This doesn’t appear to be toolchain related – anything which uses DDEUtils for long command line processing would be affected.
Modified by Jeffrey Lee (213) Mon, November 13 2023 - 22:12:38 GMT
A fix for this is currently being worked on in https://gitlab.riscosopen.org/RiscOS/Sources/Li…
There are a couple more things I need to fix, but hopefully it’ll be done soon.