Question:
I am using a Direct Web Remoting (DWR) JavaScript library file and am getting an error only in Safari (desktop and iPad)It says
Maximum call stack size exceeded.
What exactly does this error mean and does it stop processing completely?
Also any fix for
Safari
browser (Actually on the iPad Safari
, it says JS:execution exceeded timeout
which I am assuming is the same call stack issue)
Best Answer:
It means that somewhere in your code, you are calling a function which in turn calls another function and so forth, until you hit the call stack limit.This is almost always because of a recursive function with a base case that isn’t being met.
Viewing the stack
Consider this code…

As you can see, the call stack grows until it hits a limit: the browser hardcoded stack size or memory exhaustion.
In order to fix it, ensure that your recursive function has a base case which is able to be met…
If you have better answer, please add a comment about this, thank you!
Source: Stackoverflow.com
Leave a Review