[Debug] fix handling deprecated warnings and stacked errors turned into exceptions
bug #10854 [Debug] fix handling deprecated warnings and stacked errors turned into exceptions (nicolas-grekas)

This PR was merged into the 2.5-dev branch.

Discussion
----------

[Debug] fix handling deprecated warnings and stacked errors turned into exceptions

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | none
| License       | MIT
| Doc PR        | none

When no deprecation logger was registered, deprecated warnings were pretended to be handled (`return true`) when in fact there were just ignored. This is the first part fixed by this patch.
The second is in handleFatal(), when a stacked error was turned into an exception, this exception wasn't properly handled. Fixed also.

Commits
-------

95f3276 [Debug] fix handling deprecated warnings and stacked errors turned into exceptions