Altera_Forum
Honored Contributor
16 years agoCGI stack size overflow ?
Hi all,
I was wondering how to increase the stack size of a CGI program because I observed than when I tried to read more than a hundred I2C registers and print their values in a HTML page, the webserver BOA does not seem to crash (no error log and no console message) but does not respond anymore, as if the C-code never stops (looks like stack size overflow ??)... If I tried to read less than a hundred I2C registers, the CGI works perfectly and prints the results correctly !! I think about adding this simple line in the makefile located in "uClinux-dist/user/cgi-generic/" : ------------------------------------------------------- EXEC = test.cgi OBJS = test.o cgivars.o htmllib.o template.o fltflags += s 16384 all: $(EXEC) ------------------------------------------------------- in order to pass stack size from 4KB (default) to 16KB for example... Is there a better solution to avoid BOA freezing situation ?? Sorry for my poor language and thanks for your help :)