Uploaded image for project: 'Qpid Dispatch'
  1. Qpid Dispatch
  2. DISPATCH-1925

Thread race in qd_message_extend vs qd_message_stream_data_buffers

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.15.0
    • 1.16.0
    • Router Node

    Description

       
      Read of "next" pointer while it may be written by another thread.
       
      70: WARNING: ThreadSanitizer: data race (pid=18524)
      70: Write of size 8 at 0x7b54000ff790 by thread T3 (mutexes: write M1479):
      70: #0 qd_message_extend /home/travis/build/kgiusti/dispatch/src/message.c:2335 (libqpid-dispatch.so+0x82d17)
      70: #1 qd_message_stream_data_append /home/travis/build/kgiusti/dispatch/src/message.c:2890 (libqpid-dispatch.so+0x8633f)
      70: #2 handle_incoming /home/travis/build/kgiusti/dispatch/src/adaptors/tcp_adaptor.c:183 (libqpid-dispatch.so+0x58bf4)
      70: #3 handle_connection_event /home/travis/build/kgiusti/dispatch/src/adaptors/tcp_adaptor.c:567 (libqpid-dispatch.so+0x5bd2f)
      70: #4 handle_event_with_context /home/travis/build/kgiusti/dispatch/src/server.c:804 (libqpid-dispatch.so+0xe8bd9)
      70: #5 do_handle_raw_connection_event /home/travis/build/kgiusti/dispatch/src/server.c:810 (libqpid-dispatch.so+0xe8bd9)
      70: #6 handle /home/travis/build/kgiusti/dispatch/src/server.c:1090 (libqpid-dispatch.so+0xe8bd9)
      70: #7 thread_run /home/travis/build/kgiusti/dispatch/src/server.c:1122 (libqpid-dispatch.so+0xeaae7)
      70: #8 _thread_init /home/travis/build/kgiusti/dispatch/src/posix/threading.c:172 (libqpid-dispatch.so+0x93966)
      70: #9 <null> <null> (libtsan.so.0+0x2d1af)
       
      70: Previous read of size 8 at 0x7b54000ff790 by main thread:
      70: #0 qd_message_stream_data_buffers /home/travis/build/kgiusti/dispatch/src/message.c:2500 (libqpid-dispatch.so+0x8330c)
      70: #1 read_message_body /home/travis/build/kgiusti/dispatch/src/adaptors/tcp_adaptor.c:315 (libqpid-dispatch.so+0x5aede)
      70: #2 handle_outgoing /home/travis/build/kgiusti/dispatch/src/adaptors/tcp_adaptor.c:392 (libqpid-dispatch.so+0x5aede)
      70: #3 handle_connection_event /home/travis/build/kgiusti/dispatch/src/adaptors/tcp_adaptor.c:527 (libqpid-dispatch.so+0x5bcbd)
      70: #4 handle_event_with_context /home/travis/build/kgiusti/dispatch/src/server.c:804 (libqpid-dispatch.so+0xe8bd9)
      70: #5 do_handle_raw_connection_event /home/travis/build/kgiusti/dispatch/src/server.c:810 (libqpid-dispatch.so+0xe8bd9)
      70: #6 handle /home/travis/build/kgiusti/dispatch/src/server.c:1090 (libqpid-dispatch.so+0xe8bd9)
      70: #7 thread_run /home/travis/build/kgiusti/dispatch/src/server.c:1122 (libqpid-dispatch.so+0xeaae7)
      70: #8 qd_server_run /home/travis/build/kgiusti/dispatch/src/server.c:1484 (libqpid-dispatch.so+0xeb55f)
      70: #9 main_process /home/travis/build/kgiusti/dispatch/router/src/main.c:113 (qdrouterd+0x2c27)
      70: #10 main /home/travis/build/kgiusti/dispatch/router/src/main.c:367 (qdrouterd+0x2882)

      Attachments

        Activity

          People

            kgiusti Ken Giusti
            kgiusti Ken Giusti
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: