Bug 1551740: Don't gather on obsolete streams. r=mjf
authorByron Campen [:bwc] <docfaraday@gmail.com>
Fri, 17 May 2019 00:48:54 +0000
changeset 533093 d146d0379fd23b0551f5d99399d99da629071b81
parent 533092 03203f118c97c2ed7ad8f20f4f7733aeddb1fa4d
child 533094 a61d0f7aa588f29a0a30d86fd887b1267bd6f95c
push id11276
push userrgurzau@mozilla.com
push dateMon, 20 May 2019 13:11:24 +0000
treeherdermozilla-beta@847755a7c325 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmjf
bugs1551740
milestone68.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1551740: Don't gather on obsolete streams. r=mjf Differential Revision: https://phabricator.services.mozilla.com/D31269
media/mtransport/third_party/nICEr/src/ice/ice_ctx.c
media/mtransport/third_party/nICEr/src/ice/ice_media_stream.c
--- a/media/mtransport/third_party/nICEr/src/ice/ice_ctx.c
+++ b/media/mtransport/third_party/nICEr/src/ice/ice_ctx.c
@@ -806,18 +806,21 @@ int nr_ice_gather(nr_ice_ctx *ctx, NR_as
 
     r_log(LOG_ICE,LOG_DEBUG,"ICE(%s): Initializing candidates",ctx->label);
     ctx->done_cb=done_cb;
     ctx->cb_arg=cb_arg;
 
     /* Initialize all the media stream/component pairs */
     stream=STAILQ_FIRST(&ctx->streams);
     while(stream){
-      if(r=nr_ice_media_stream_initialize(ctx,stream))
-        ABORT(r);
+      if(!stream->obsolete) {
+        if(r=nr_ice_media_stream_initialize(ctx,stream)) {
+          ABORT(r);
+        }
+      }
 
       stream=STAILQ_NEXT(stream,entry);
     }
 
     if(ctx->uninitialized_candidates)
       ABORT(R_WOULDBLOCK);
 
     _status=0;
--- a/media/mtransport/third_party/nICEr/src/ice/ice_media_stream.c
+++ b/media/mtransport/third_party/nICEr/src/ice/ice_media_stream.c
@@ -132,16 +132,18 @@ int nr_ice_media_stream_destroy(nr_ice_m
     return(0);
   }
 
 int nr_ice_media_stream_initialize(nr_ice_ctx *ctx, nr_ice_media_stream *stream)
   {
     int r,_status;
     nr_ice_component *comp;
 
+    assert(!stream->obsolete);
+
     comp=STAILQ_FIRST(&stream->components);
     while(comp){
       if(r=nr_ice_component_initialize(ctx,comp))
         ABORT(r);
       comp=STAILQ_NEXT(comp,entry);
     }
 
     _status=0;