1
0
mirror of https://github.com/mariadb-corporation/mariadb-connector-c.git synced 2025-08-05 15:55:58 +03:00
Commit Graph

7 Commits

Author SHA1 Message Date
Vladislav Vaintroub
d9626e315e CONC-666: Fix memory allocation issue with prepared statement reexecution.
Connector is using a memory root for the result set, and
mysql_stmt_execute()/mysql_stmt_store_result(), when executed in a loop,
leads to series of ma_alloc_root() and ma_free_root() calls for the same
memory root.

The problem is that ma_alloc_root() calculates the allocation size based
on MA_MEM_ROOT::block_num, this value is incremented for larger allocation,
but is never reset. As a result, the allocation size continuously
grows, for an empty memroot.

This patch resets MA_MEM_ROOT::block_num in ma_free_root().
2023-09-20 23:01:44 +02:00
Georg Richter
b10c4f9e7b Fix for CONC-231: Incorrect FSF address 2017-02-05 11:35:11 +01:00
Sergei Golubchik
4ff192bb40 few bugs in the tracker support
* ma_multi_malloc wanted uint for size arguments, not size_t
* ma_multi_malloc needs NULL pointer at the end. Simple 0
  is not always the right size
* don't look for tracker info, if the packet does not even
  has the info_len field
2016-09-21 17:35:54 +02:00
Georg Richter
7b14603438 Fix for CONC-196: merged manually from connector_c_2.3 branch 2016-08-03 12:30:54 +02:00
Georg Richter
d5c5f9a386 Fixed memory overrun in my_strdup_root 2016-06-02 11:00:24 +02:00
Georg Richter
b4efe73c9e session tracking implementation (10.2-integration):
- At the moment the following session tracking types are supported:
  SESSION_TRACK_SCHEMA
  SESSION_TRACK_SYSTEM_VARIABLES
  SESSION_TRACK_STATE_CHANGE
  SESSION_TRACK_TRANSACTION_CHARACTERISTICS
- New API functions
  mysql_session_track_get_next
  mysql_session_track_get_first
2016-03-31 08:41:12 +02:00
Georg Richter
4ca933bb81 Global cleanup:
removed global locks
  removed dead code and files
  removed dbug
2016-02-08 18:43:02 +01:00