From 36eda7cf0e16656fb4fcb7dd5e93b5555b824e56 Mon Sep 17 00:00:00 2001 From: "wu@webrtc.org" Date: Tue, 15 Apr 2014 20:37:30 +0000 Subject: [PATCH] Workaround for https://bugzilla.mozilla.org/show_bug.cgi?id=996329, where the m line from firefox have a space at the end. For example: "m=application 38233 DTLS/SCTP 5000 " BUG=3212 TEST=manually try to use DataChannel between FF 28 and Chrome with rtccopy.com R=jiayl@webrtc.org Review URL: https://webrtc-codereview.appspot.com/12029005 git-svn-id: http://webrtc.googlecode.com/svn/trunk@5915 4adac7df-926f-26a2-2b94-8c16560cd09d --- talk/app/webrtc/webrtcsdp.cc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/talk/app/webrtc/webrtcsdp.cc b/talk/app/webrtc/webrtcsdp.cc index 1b3e6f566..2a773b63d 100644 --- a/talk/app/webrtc/webrtcsdp.cc +++ b/talk/app/webrtc/webrtcsdp.cc @@ -2115,6 +2115,12 @@ bool ParseMediaDescription(const std::string& message, // std::vector codec_preference; for (size_t j = 3 ; j < fields.size(); ++j) { + // TODO(wu): Remove when below bug is fixed. + // https://bugzilla.mozilla.org/show_bug.cgi?id=996329 + if (fields[j] == "" && j == fields.size() - 1) { + continue; + } + int pl = 0; if (!GetValueFromString(line, fields[j], &pl, error)) { return false;