[Xcb] [Bug 30343] New: XCB leaks memory and socket file descriptor on connection failure.

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Thu Sep 23 05:04:14 PDT 2010


https://bugs.freedesktop.org/show_bug.cgi?id=30343

           Summary: XCB leaks memory and socket file descriptor on
                    connection failure.
           Product: XCB
           Version: unspecified
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: patch
          Severity: normal
          Priority: medium
         Component: Library
        AssignedTo: xcb at lists.freedesktop.org
        ReportedBy: jp.sittingduck at gmail.com
         QAContact: xcb at lists.freedesktop.org


Created an attachment (id=38899)
 --> (https://bugs.freedesktop.org/attachment.cgi?id=38899)
A test-case to show leak.

When there is a connection error, XCB sets has_error to 1 in xcb_connection_t,
which precludes clean-up (since, if has_error is set to 1, the connection may
be a pointer to the error_connection variable). Attached is a test-case that
simulates a connection failure. Running it in valgrind will show not only a
memory leak, but a file descriptor leak (the socket) too.

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the Xcb mailing list