| Bug #77532 | Replace CATCH_ALL macro with function | ||
|---|---|---|---|
| Submitted: | 29 Jun 2015 8:58 | Modified: | 30 Jun 2015 16:01 |
| Reporter: | Norvald Ryeng | Email Updates: | |
| Status: | Closed | Impact on me: | |
| Category: | MySQL Server: GIS | Severity: | S3 (Non-critical) |
| Version: | 5.7.8 | OS: | Any |
| Assigned to: | CPU Architecture: | Any | |
[30 Jun 2015 16:01]
Paul DuBois
Fixed in 5.7.8. Code cleanup. No changelog entry needed.

Description: Replace the CATCH_ALL macro with a function to aid debugging and improve code readability. How to repeat: . Suggested fix: Replace the pattern try { ... something that may throw ... } CATCH_ALL(funcname, expr); with try { ... something that may throw ... } catch (...) { expr; handle_gis_exception(funcname); } and void handle_gis_exception(char *funcname) { try { throw; } catch (ExceptionTypeA&) { ... handle it ... } catch (ExceptionTypeB&) { ... handle it ... } catch (...) { ... handle it ... } }