How to increase stack limit permanently without restarting
What's wrong with editing your .bashrc
file to do a ulimit -s size
every time you start a terminal session?
If you want to do this programatically, you can use the setrlimit()
function.