Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
OPTIONS, DESCRIBE, SETUP, SET_PARAMETER, SET_PARAMETER, PLAY
Returns True if it sent a packet, False if it didn't """
if not self.sent_options:
self.sent_options = True
self._sendOptions()
return True
if not self.sent_describe:
print 'sending describe'
self.sent_describe = True
self._sendDescribe()
return True
if len(self.streamids) > len(self.setup_streamids):
headers = {}
if not self.sent_realchallenge2:
self.sent_realchallenge2 = True
challenge_tuple = RealChallenge.compute(self.realchallenge1)
headers['RealChallenge2'] = '%s, sd=%s' % challenge_tuple
# Gets a streamid that hasn't been setup yet
s = [s for s in self.streamids if s not in self.setup_streamids][0]
self.setup_streamids.append(s)
self._sendSetup(streamid=s, headers=headers)
return True
if not self.sent_parameter:
self.sent_parameter = True
self._sendSetParameter('Subscribe', self.subscribe)
return True
if not self.sent_bandwidth:
self.sent_bandwidth = True
self._sendSetParameter('SetDeliveryBandwidth',
'Bandwidth=%s;BackOff=0' % self.factory.bandwidth)
return True
if not self.sent_play: