Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Double free in mariadb #220

Open
Octogonapus opened this issue Aug 28, 2024 · 0 comments
Open

Double free in mariadb #220

Octogonapus opened this issue Aug 28, 2024 · 0 comments

Comments

@Octogonapus
Copy link
Contributor

Octogonapus commented Aug 28, 2024

I ran into a double free. My program is using execute(db, ...) on multiple threads but it's guarded by a lock so no two executes can run concurrently. I've also experienced a few crashes which seem related (just segfaults with no printout).

MySQL v1.4.6
MariaDB_Connector_C_jll v3.1.12+0

double free or corruption (fasttop)

[2167724] signal (6.-6): Aborted
in expression starting at REPL[48]:1
pthread_kill at /lib/x86_64-linux-gnu/libc.so.6 (unknown line)
raise at /lib/x86_64-linux-gnu/libc.so.6 (unknown line)
abort at /lib/x86_64-linux-gnu/libc.so.6 (unknown line)
unknown function (ip: 0x7f0132879675)
unknown function (ip: 0x7f0132890cfb)
unknown function (ip: 0x7f01328929c9)
free at /lib/x86_64-linux-gnu/libc.so.6 (unknown line)
SSL_free at /home/salmon/.julia/artifacts/69903d1a57355b6e78750aac3a8b3fddab87180f/lib/libssl.so (unknown line)
ma_tls_close at /home/salmon/.julia/artifacts/c688df815e86a92f5f36c990983dd26d8a80f17a/lib/mariadb/libmariadb.so (unknown line)
ma_pvio_close at /home/salmon/.julia/artifacts/c688df815e86a92f5f36c990983dd26d8a80f17a/lib/mariadb/libmariadb.so (unknown line)
mthd_my_send_cmd at /home/salmon/.julia/artifacts/c688df815e86a92f5f36c990983dd26d8a80f17a/lib/mariadb/libmariadb.so (unknown line)
mysql_stmt_execute at /home/salmon/.julia/artifacts/c688df815e86a92f5f36c990983dd26d8a80f17a/lib/mariadb/libmariadb.so (unknown line)
mysql_stmt_execute at /home/salmon/.julia/packages/MySQL/NMNbH/src/api/ccalls.jl:8 [inlined]
execute at /home/salmon/.julia/packages/MySQL/NMNbH/src/api/papi.jl:3 [inlined]
#execute#35 at /home/salmon/.julia/packages/MySQL/NMNbH/src/prepare.jl:162
execute at /home/salmon/.julia/packages/MySQL/NMNbH/src/prepare.jl:152
unknown function (ip: 0x7eff73f23349)
_jl_invoke at /cache/build/builder-amdci4-4/julialang/julia-release-1-dot-10/src/gf.c:2895 [inlined]
ijl_apply_generic at /cache/build/builder-amdci4-4/julialang/julia-release-1-dot-10/src/gf.c:3077
#82 at /home/salmon/git/project/main.jl:70
lock at ./lock.jl:229
unknown function (ip: 0x7eff73fed249)
_jl_invoke at /cache/build/builder-amdci4-4/julialang/julia-release-1-dot-10/src/gf.c:2895 [inlined]
ijl_apply_generic at /cache/build/builder-amdci4-4/julialang/julia-release-1-dot-10/src/gf.c:3077
#81 at /home/salmon/git/project/main.jl:69
unknown function (ip: 0x7eff73fea5b2)
_jl_invoke at /cache/build/builder-amdci4-4/julialang/julia-release-1-dot-10/src/gf.c:2895 [inlined]
ijl_apply_generic at /cache/build/builder-amdci4-4/julialang/julia-release-1-dot-10/src/gf.c:3077
jl_apply at /cache/build/builder-amdci4-4/julialang/julia-release-1-dot-10/src/julia.h:1982 [inlined]
start_task at /cache/build/builder-amdci4-4/julialang/julia-release-1-dot-10/src/task.c:1238
Allocations: 121462440 (Pool: 121313001; Big: 149439); GC: 60
[1]    2167724 IOT instruction (core dumped)  julia -t auto --project
julia> versioninfo()
Julia Version 1.10.5
Commit 6f3fdf7b362 (2024-08-27 14:19 UTC)
Build Info:
  Official https://julialang.org/ release
Platform Info:
  OS: Linux (x86_64-linux-gnu)
  CPU: 32 × 13th Gen Intel(R) Core(TM) i9-13900K
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-15.0.7 (ORCJIT, goldmont)
Threads: 32 default, 0 interactive, 16 GC (on 32 virtual cores)

kernel 5.15.153.1-microsoft-standard-WSL2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant