What happens to a php script which goes like this?
class FooException extends Exception
{
public function __construct() {
throw new FooException;
}
}
It’s probably same as
while (TRUE) {
new Exception();
}
It simply time outs when execution time is exceeded, or fails with some fatal error?
In the first case nothing happens, because you never construct the exception.
In the second case the exception is not thrown so you just get an ordinary infinite loop.
However if you modify the first example by adding this line at the end:
It causes an infinite loop which eventually consumes all the memory: