Uploaded image for project: 'Qpid Proton'
  1. Qpid Proton
  2. PROTON-1824

[python] Use of proton.Array causes SIGSEGV in Proton encoder

    XMLWordPrintableJSON

Details

    Description

      Using proton.Array as a message body in Python 2.7 causes a segmentation fault in Proton.

      A reproducer which is based on the Python examples simple_send.py is attached. The trace (lastĀ sevenĀ frames only) is as follows:

      (gdb) bt
      #0 0x00007f54f71b27de in pn_encoder_writef32 (encoder=0x55f61e8602f0, value=512110782) at /home/kvdr/RedHat/qpid-proton/c/src/core/encoder.c:183
      #1 0x00007f54f71b3369 in pni_encoder_exit (ctx=0x55f61e8602f0, data=0x55f61e85fd70, node=0x55f61e863a98) at /home/kvdr/RedHat/qpid-proton/c/src/core/encoder.c:381
      #2 0x00007f54f71af26f in pni_data_traverse (data=0x55f61e85fd70, enter=0x7f54f71b2b8f <pni_encoder_enter>, exit=0x7f54f71b31bd <pni_encoder_exit>, ctx=0x55f61e8602f0)
      at /home/kvdr/RedHat/qpid-proton/c/src/core/codec.c:1264
      #3 0x00007f54f71b3417 in pn_encoder_encode (encoder=0x55f61e8602f0, src=0x55f61e85fd70, dst=0x55f61e8630a0 "", size=16) at /home/kvdr/RedHat/qpid-proton/c/src/core/encoder.c:401
      #4 0x00007f54f71af925 in pn_data_encode (data=0x55f61e85fd70, bytes=0x55f61e8630a0 "", size=16) at /home/kvdr/RedHat/qpid-proton/c/src/core/codec.c:1441
      #5 0x00007f54f71c693d in pn_message_encode (msg=0x55f61e84ec40, bytes=0x55f61e8630a0 "", size=0x7fff60a71d10) at /home/kvdr/RedHat/qpid-proton/c/src/core/message.c:764
      #6 0x00007f54f742071c in _wrap_pn_message_encode (self=0x0, args=0x7f54f2a2a440) at /home/kvdr/RedHat/qpid-proton/build/python/cprotonPYTHON_wrap.c:4098
      

      Attachments

        1. simple_send.py
          2 kB
          Kim van der Riet

        Activity

          People

            astitcher Andrew Stitcher
            kpvdr Kim van der Riet
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: