• Lambros Lambrou's avatar
    [remoting host] Fix div-by-zero in LeakyBucket · e0ef90be
    Lambros Lambrou authored
    When receiving a bandwidth estimate of 0 from WebRTC, the host should
    pause the video stream without crashing. This CL is a simple fix which
    sets the bucket-emptying time to 1 minute if the rate is set to 0. This
    is similar to what we already do in
    FrameProcessingTimeEstimator::EstimatedTransitTime().
    
    Bug: 806918
    Change-Id: I43bf24cf54250cc3856adeb4c49809733320d46b
    Reviewed-on: https://chromium-review.googlesource.com/891671Reviewed-by: default avatarJoe Downing <joedow@chromium.org>
    Commit-Queue: Lambros Lambrou <lambroslambrou@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#532567}
    e0ef90be
leaky_bucket.cc 1.75 KB