I have a C # program that uses a C ++ / cli dll. The dll contains a lot of legacy code consisting of several win32 windows.
The problem is that windows in the dll require a bit more stacks than an average cough. Since these are not background processes, but win32 api, I need to increase the stack size of the GUI thread (at least I think win32 api in the dll will use the main gui process).
So, I need a way to increase the size of the GUI thread in a C # process.
Since I did not find any settings for this, I tried editbin / STACK from the command line, which works. The problem is that it only works on the command line, if I try to enter it as a post-assembly, for some reason the size of the binary file stack will not change, although the postbuild step is executed correctly and does not throw an error :(
editbin.exe /STACK:2097152 $(TargetPath)
(Editbin.exe is in the path and there is no error in the output window)
So, how do I get a larger stack size for my C ++ dll?
[Update]
I noticed a problem using editbin.exe.
This does not work, either on the command line or in the post build step:
editbin.exe /STACK:2097152 c:\some\path\bin\release\app.exe
This works on the command line, but not as a build step:
editbin.exe /STACK:2097152 app.exe
But I need it to work as a post build step. I tried putting it in a batch file, echo'd, to make sure the call and working directory were ok, but it still doesn't work. Itβs strange.
c # stack-overflow dll c ++ - cli
Sam Apr 04 2018-11-12T00: 00Z
source share