xpra icon
Bug tracker and wiki

This bug tracker and wiki are being discontinued
please use https://github.com/Xpra-org/xpra instead.


Ticket #1118: sink_changes.diff

File sink_changes.diff, 1.2 KB (added by Kundan, 5 years ago)

sink.py changes to resolve LEAK error.

  • sink.py

     
    268268        if not self.src:
    269269            log("add_data(..) dropped, no source")
    270270            return
    271         if self.state=="stopped":
    272             log("add_data(..) dropped, pipeline is stopped")
    273             return
     271       # if self.state=="stopped":
     272       #     log("add_data(..) dropped, pipeline is stopped")
     273       #     return
    274274        #having a timestamp causes problems with the queue and overruns:
    275275        log("add_data(%s bytes, %s) queue_state=%s", len(data), metadata, self.queue_state)
    276276        buf = gst.new_buffer(data)
     
    352352        print("loaded %s bytes from %s" % (len(data), filename))
    353353        #force no leak since we push all the data at once
    354354        global QUEUE_LEAK, GST_QUEUE_NO_LEAK, QUEUE_SILENT
    355         QUEUE_LEAK = GST_QUEUE_NO_LEAK
     355      #  QUEUE_LEAK = GST_QUEUE_NO_LEAK
     356        QUEUE_LEAK = 0
    356357        QUEUE_SILENT = 1
    357         ss = SoundSink(codec=codec)
     358        ss = SoundSink(codecs=codec)
     359#        ss = SoundSink(codec)
    358360        ss.add_data(data)
    359361        def eos(*args):
    360362            print("eos")