Skip to content

Commit

Permalink
Prevent errors for SDP parsing in recent GStreamer versions
Browse files Browse the repository at this point in the history
  • Loading branch information
ehfd committed Nov 28, 2022
1 parent 87d9771 commit 52631b9
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/selkies_gstreamer/gstwebrtc_app.py
Original file line number Diff line number Diff line change
Expand Up @@ -657,8 +657,7 @@ def set_sdp(self, sdp_type, sdp):
if sdp_type != 'answer':
raise GSTWebRTCAppError('ERROR: sdp type was not "answer"')

_, sdpmsg = GstSdp.SDPMessage.new()
GstSdp.sdp_message_parse_buffer(bytes(sdp.encode()), sdpmsg)
_, sdpmsg = GstSdp.SDPMessage.new_from_text(sdp)
answer = GstWebRTC.WebRTCSessionDescription.new(
GstWebRTC.WebRTCSDPType.ANSWER, sdpmsg)
promise = Gst.Promise.new()
Expand Down

0 comments on commit 52631b9

Please sign in to comment.