[MDEV-29490] rename internally used client API to avoid name conflicts with C/C Created: 2022-09-07 Updated: 2023-11-27 Resolved: 2022-10-25 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Server |
| Fix Version/s: | 10.3.37, 10.4.27, 10.5.18, 10.6.11, 10.7.7, 10.8.6, 10.9.4, 10.10.2 |
| Type: | Task | Priority: | Blocker |
| Reporter: | Sergei Golubchik | Assignee: | Lawrin Novitsky |
| Resolution: | Fixed | Votes: | 1 |
| Labels: | None | ||
| Issue Links: |
|
||||||||||||||||||||
| Description |
|
MariaDB server has remnants of libmysqlclient used internally (for replicaiton, CONNECT, Federated, Spider, etc). Connector/C has many symbols with exactly same names, so if a server would load libmariadb.so, directly or indirectly, one can get symbols mixed up, causing problems. A possible scenario — server loads CONNECT engine (ha_connect.so), the latter uses ODBC to connect to another MariaDB server. ODBC library loads MariaDB Connector/ODBC driver, and that driver is dynamically linked with libmariadb.so. A possible outcome — ODBC could use mysql_connect from libmariadb.so to connect, but mysql_close from the server to disconnect. Or vice versa. To avoid these problems the internal server implementation of the client API should be renamed. |
| Comments |
| Comment by Lawrin Novitsky [ 2022-10-05 ] |
|
julien.fritsch The fix has been pushed and is being tested. As result of testing additional changes are made. So far it's like disabling certain irrelevant tests. |
| Comment by Lawrin Novitsky [ 2022-10-17 ] |
|
Seemingly all is fine by now. One issue, that was found, has been fixed by Sergey, so it's waiting for other things to be finished. |
| Comment by Lawrin Novitsky [ 2022-10-24 ] |
|
Please review the code for this MDEV |
| Comment by Sergei Golubchik [ 2022-10-25 ] |
|
Looks good. Please, squash commits b3dc4ae9075, 67dc9e712b1, cb0bb395b80 into one and push. |
| Comment by Lawrin Novitsky [ 2022-10-26 ] |
|
In versions, where sql service is present, i.e. from 10.6, the code from this MDEV depends on the code in linked |