Skip to content

Fix INFO SENTINEL memory leak#10268

Merged
oranagra merged 2 commits intoredis:unstablefrom
enjoy-binbin:fix_info_sentinel_memory_leak
Feb 9, 2022
Merged

Fix INFO SENTINEL memory leak#10268
oranagra merged 2 commits intoredis:unstablefrom
enjoy-binbin:fix_info_sentinel_memory_leak

Conversation

@enjoy-binbin
Copy link
Contributor

Introduced in #6891

@enjoy-binbin enjoy-binbin added the state:to-be-merged The PR should be merged soon, even if not yet ready, this is used so that it won't be forgotten label Feb 9, 2022
@enjoy-binbin
Copy link
Contributor Author

enjoy-binbin commented Feb 9, 2022

Found it in daily ci: https://github.com/redis/redis/runs/5118013343?check_suite_focus=true#step:8:201

=================================================================
==36792==ERROR: LeakSanitizer: detected memory leaks

Direct leak of 32 byte(s) in 8 object(s) allocated from:
    #0 0x7f1fbdb4fbc8 in malloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10dbc8)
    #1 0x56516634b11f in ztrymalloc_usable /home/runner/work/redis/redis/src/zmalloc.c:108
    #2 0x56516634b1e5 in zmalloc_usable /home/runner/work/redis/redis/src/zmalloc.c:140
    #3 0x56516633945a in _sdsnewlen /home/runner/work/redis/redis/src/sds.c:117
    #4 0x56516649b97e in sentinelInfoCommand /home/runner/work/redis/redis/src/sentinel.c:4136
    #5 0x5651663356ff in infoCommand /home/runner/work/redis/redis/src/server.c:5745
    #6 0x565166324e10 in call /home/runner/work/redis/redis/src/server.c:3167
    #7 0x565166329d87 in processCommand /home/runner/work/redis/redis/src/server.c:3761
    #8 0x565166379c71 in processCommandAndResetClient /home/runner/work/redis/redis/src/networking.c:2248
    #9 0x56516638265c in processInputBuffer /home/runner/work/redis/redis/src/networking.c:2343
    #10 0x56516638a387 in readQueryFromClient /home/runner/work/redis/redis/src/networking.c:2455
    #11 0x56516654f01c in callHandler /home/runner/work/redis/redis/src/connhelpers.h:79
    #12 0x56516654f01c in connSocketEventHandler /home/runner/work/redis/redis/src/connection.c:295
    #13 0x565166310661 in aeProcessEvents /home/runner/work/redis/redis/src/ae.c:436
    #14 0x56516631145c in aeMain /home/runner/work/redis/redis/src/ae.c:496
    #15 0x5651662f6d6f in main /home/runner/work/redis/redis/src/server.c:6907
    #16 0x7f1fbd6ff0b2 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x270b2)

SUMMARY: AddressSanitizer: 32 byte(s) leaked in 8 allocation(s).

@oranagra oranagra merged commit beb94c9 into redis:unstable Feb 9, 2022
@enjoy-binbin enjoy-binbin deleted the fix_info_sentinel_memory_leak branch February 9, 2022 06:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

state:to-be-merged The PR should be merged soon, even if not yet ready, this is used so that it won't be forgotten

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants