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

regcomp leak introduced in f97565 #56

Open
00pauln00 opened this issue Apr 1, 2021 · 0 comments
Open

regcomp leak introduced in f97565 #56

00pauln00 opened this issue Apr 1, 2021 · 0 comments
Assignees

Comments

@00pauln00
Copy link
Owner

f97565a introduces a minor leak where a compiled regex is not freed.

<574.109560627:warn:raft-net-test:raft_net_init@2357> enter
<574.110220321:warn:raft-net-test:raft_net_init@2367> exit
<574.110609917:warn:raft-net-test:raft_net_client_user_id_parse@2275> 1a636bd0-d27d-11ea-8cad-90324b2d1e89:2341523123:32452300123:1:0

=================================================================
==21243==ERROR: LeakSanitizer: detected memory leaks

Direct leak of 256 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743bc8 in malloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dbc8)
#1 0x7f338a4054f5 in regcomp (/lib/x86_64-linux-gnu/libc.so.6+0x1024f5)

Direct leak of 224 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743ffe in __interceptor_realloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dffe)
#1 0x7f338a404ab4 (/lib/x86_64-linux-gnu/libc.so.6+0x101ab4)

Indirect leak of 2048 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743dc6 in calloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10ddc6)
#1 0x7f338a403678 (/lib/x86_64-linux-gnu/libc.so.6+0x100678)

Indirect leak of 1888 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743bc8 in malloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dbc8)
#1 0x7f338a403b5b (/lib/x86_64-linux-gnu/libc.so.6+0x100b5b)

Indirect leak of 1888 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743bc8 in malloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dbc8)
#1 0x7f338a403641 (/lib/x86_64-linux-gnu/libc.so.6+0x100641)

Indirect leak of 1888 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743bc8 in malloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dbc8)
#1 0x7f338a403b6b (/lib/x86_64-linux-gnu/libc.so.6+0x100b6b)

Indirect leak of 1296 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743bc8 in malloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dbc8)
#1 0x7f338a404476 (/lib/x86_64-linux-gnu/libc.so.6+0x101476)

Indirect leak of 952 byte(s) in 81 object(s) allocated from:
#0 0x7f338a743ffe in __interceptor_realloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dffe)
#1 0x7f338a404556 (/lib/x86_64-linux-gnu/libc.so.6+0x101556)

Indirect leak of 472 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743bc8 in malloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dbc8)
#1 0x7f338a403b3a (/lib/x86_64-linux-gnu/libc.so.6+0x100b3a)

Indirect leak of 316 byte(s) in 66 object(s) allocated from:
#0 0x7f338a743bc8 in malloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dbc8)
#1 0x7f338a3f7c69 (/lib/x86_64-linux-gnu/libc.so.6+0xf4c69)

Indirect leak of 256 byte(s) in 8 object(s) allocated from:
#0 0x7f338a743dc6 in calloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10ddc6)
#1 0x7f338a4000ee (/lib/x86_64-linux-gnu/libc.so.6+0xfd0ee)

Indirect leak of 88 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743dc6 in calloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10ddc6)
#1 0x7f338a3f9d93 (/lib/x86_64-linux-gnu/libc.so.6+0xf6d93)

Indirect leak of 64 byte(s) in 8 object(s) allocated from:
#0 0x7f338a743bc8 in malloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dbc8)
#1 0x7f338a4042fa (/lib/x86_64-linux-gnu/libc.so.6+0x1012fa)

Indirect leak of 64 byte(s) in 16 object(s) allocated from:
#0 0x7f338a743bc8 in malloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dbc8)
#1 0x7f338a40428a (/lib/x86_64-linux-gnu/libc.so.6+0x10128a)

Indirect leak of 40 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743ffe in __interceptor_realloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dffe)
#1 0x7f338a3f41f4 (/lib/x86_64-linux-gnu/libc.so.6+0xf11f4)
#2 0x6020000053cf ()

Indirect leak of 32 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743ffe in __interceptor_realloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dffe)
#1 0x7f338a3f41f4 (/lib/x86_64-linux-gnu/libc.so.6+0xf11f4)
#2 0x60200000568f ()

Indirect leak of 32 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743ffe in __interceptor_realloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dffe)
#1 0x7f338a3f41f4 (/lib/x86_64-linux-gnu/libc.so.6+0xf11f4)
#2 0x60200000554f ()

Indirect leak of 32 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743ffe in __interceptor_realloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dffe)
#1 0x7f338a3f41f4 (/lib/x86_64-linux-gnu/libc.so.6+0xf11f4)
#2 0x6020000053ef ()

Indirect leak of 32 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743ffe in __interceptor_realloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dffe)
#1 0x7f338a3f41f4 (/lib/x86_64-linux-gnu/libc.so.6+0xf11f4)
#2 0x60200000528f ()

Indirect leak of 16 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743ffe in __interceptor_realloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dffe)
#1 0x7f338a3f2bc3 (/lib/x86_64-linux-gnu/libc.so.6+0xefbc3)

Indirect leak of 4 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743bc8 in malloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dbc8)
#1 0x7f338a3f2ad2 (/lib/x86_64-linux-gnu/libc.so.6+0xefad2)

Indirect leak of 4 byte(s) in 1 object(s) allocated from:
#0 0x7f338a743bc8 in malloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dbc8)
#1 0x7f338a3f9dcf (/lib/x86_64-linux-gnu/libc.so.6+0xf6dcf)

SUMMARY: AddressSanitizer: 12348 byte(s) leaked in 206 allocation(s).
FAIL test/raft-net-test (exit status: 1)

@manishasalve manishasalve self-assigned this Apr 15, 2021
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

2 participants