Details
-
Bug
-
Status: Closed (View Workflow)
-
Minor
-
Resolution: Fixed
-
1.2.1
-
None
Description
When a sufficiently large message is logged MaxScale receives a segmentation fault due to a failure to allocate enough memory on the stack. This only happens with extremely large log messages but for example the readwritesplit and readconnroute modules both log queries to the trace log. If one were to do a large enough bulk insert, MaxScale would crash.
A simple fix to this would be to set an upper limit to the log message length before anything is done. There is a hard limit imposed by the block buffer size of 4k but the allocation of stack memory is done before that.