[Bugs] [Bug 1342620] libglusterfs: race conditions and illegal mem access in timer

bugzilla at redhat.com bugzilla at redhat.com
Wed Jun 8 12:15:25 UTC 2016


https://bugzilla.redhat.com/show_bug.cgi?id=1342620



--- Comment #2 from Vijay Bellur <vbellur at redhat.com> ---
COMMIT: http://review.gluster.org/14644 committed in release-3.8 by Kaleb
KEITHLEY (kkeithle at redhat.com) 
------
commit 8d99b1860dbaa62da3edb1ec9fd626f51f9d2c95
Author: Kaleb S KEITHLEY <kkeithle at redhat.com>
Date:   Fri Jun 3 13:29:00 2016 -0400

    libglusterfs (timer): race conditions, illegal mem access, mem leak

    While investigating gfapi memory consumption with valgrind, valgrind
    reported several memory access issues.

    Also see the timer 'registry' being recreated (shortly) after being
    freed during teardown due to the way it's currently written.

    Passing ctx as data to gf_timer_proc() is prone to memory access
    issues if ctx is freed before gf_timer_proc() terminates. (And in
    fact this does happen, at least in valgrind.) gf_timer_proc() doesn't
    need ctx for anything, it only needs ctx->timer, so just pass that.

    Nothing ever calls gf_timer_registry_init(). Nothing outside of
    timer.c that is. Making it and gf_timer_proc() static.

    backport mainline:
    > http://review.gluster.org/14247
    > BUG: 1333925

    Change-Id: Ia28454dda0cf0de2fec94d76441d98c3927a906a
    BUG: 1342620
    Signed-off-by: Kaleb S KEITHLEY <kkeithle at redhat.com>
    Reviewed-on: http://review.gluster.org/14644
    Smoke: Gluster Build System <jenkins at build.gluster.com>
    NetBSD-regression: NetBSD Build System <jenkins at build.gluster.org>
    CentOS-regression: Gluster Build System <jenkins at build.gluster.com>

-- 
You are receiving this mail because:
You are on the CC list for the bug.
Unsubscribe from this bug https://bugzilla.redhat.com/token.cgi?t=91oWOK2P56&a=cc_unsubscribe


More information about the Bugs mailing list