Qualify cmath functions.

Bug: None
Change-Id: Id561750eb6c2e26588e505beb3800e97075adb87
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/127782
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27130}
This commit is contained in:
Mirko Bonadei
2019-03-14 11:57:14 +01:00
committed by Commit Bot
parent b0f968a761
commit 1ddc7634fd
2 changed files with 4 additions and 3 deletions

View File

@ -13,6 +13,7 @@
#include <assert.h>
#include <math.h>
#include <algorithm>
#include <cmath>
#include <limits>
#include <list>
#include <vector>
@ -422,7 +423,7 @@ int TcpSender::GetFeedbackIntervalMs() const {
}
void TcpSender::SendPackets(Packets* in_out) {
int cwnd = ceil(cwnd_);
int cwnd = std::ceil(cwnd_);
int packets_to_send = std::max(cwnd - static_cast<int>(in_flight_.size()), 0);
int timed_out = TriggerTimeouts();
if (timed_out > 0) {

View File

@ -84,9 +84,9 @@ class DownscaledVideo : public rtc::RefCountedObject<Video> {
public:
DownscaledVideo(float scale_factor, const rtc::scoped_refptr<Video>& video)
: downscaled_width_(
static_cast<int>(round(scale_factor * video->width()))),
static_cast<int>(std::round(scale_factor * video->width()))),
downscaled_height_(
static_cast<int>(round(scale_factor * video->height()))),
static_cast<int>(std::round(scale_factor * video->height()))),
video_(video) {}
int width() const override { return downscaled_width_; }