[MXS-1338] Buffer objects are bound to indiviudual buffers Created: 2017-08-01  Updated: 2020-08-25  Resolved: 2017-08-02

Status: Closed
Project: MariaDB MaxScale
Component/s: Core
Affects Version/s: 2.1.5
Fix Version/s: 2.1.6

Type: Bug Priority: Blocker
Reporter: markus makela Assignee: markus makela
Resolution: Fixed Votes: 1
Labels: None


 Description   

When the buffer objects (i.e. the generated parse tree of the SQL statement) is stored, it is stored in the buffer itself, not the underlying shared memory buffer. This leads to a memory leak when a buffer is cloned, the original buffer is parsed and then freed and finally the cloned buffer is freed.

The reference count of the shared memory buffer drops down to zero and the buffer objects are freed when the cloned buffer is being freed but the cloned buffer doesn't know about the buffer object that was created after the cloning process as the buffer objects are bound to individual buffers.

The fix to this is to make the buffer objects a part of the shared memory buffer, as I would suspect the original idea was.



 Comments   
Comment by Dipti Joshi (Inactive) [ 2017-08-07 ]

markus makelaHow was this fixed ?

Comment by markus makela [ 2017-08-07 ]

The fix to this was to make the buffer objects a part of the shared memory buffer.

Generated at Thu Feb 08 04:05:59 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.