Seldaek/monolog — pull request #54 by allmarkedup (2012-02-11 11:14:30+00:00)
Title: Prevent exceptions from being thrown in file handler destructors

In certain setups I was getting a 'Exception thrown without a stack frame' error on first run of the day when the rotating file handler was used (and so the log file had not been yet created). Appears that the handler was trying to close a non-existent stream which was then throwing an exception in the destructor, causing the issue.

Wrapping this call to the close method in a try/catch block will prevent this 'no stack frame' exception error from occurring.