Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(432)

Side by Side Diff: webrtc/media/sctp/sctpdataengine.cc

Issue 1753293002: Safe numeric library: base/numerics (copied from Chromium) (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Rebase with master + correct new safe_conversions.h include Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
11 #include "webrtc/media/sctp/sctpdataengine.h" 11 #include "webrtc/media/sctp/sctpdataengine.h"
12 12
13 #include <stdarg.h> 13 #include <stdarg.h>
14 #include <stdio.h> 14 #include <stdio.h>
15 15
16 #include <memory> 16 #include <memory>
17 #include <sstream> 17 #include <sstream>
18 #include <vector> 18 #include <vector>
19 19
20 #include "usrsctplib/usrsctp.h" 20 #include "usrsctplib/usrsctp.h"
21 #include "webrtc/base/arraysize.h" 21 #include "webrtc/base/arraysize.h"
22 #include "webrtc/base/buffer.h" 22 #include "webrtc/base/buffer.h"
23 #include "webrtc/base/helpers.h" 23 #include "webrtc/base/helpers.h"
24 #include "webrtc/base/logging.h" 24 #include "webrtc/base/logging.h"
25 #include "webrtc/base/safe_conversions.h" 25 #include "webrtc/base/numerics/safe_conversions.h"
26 #include "webrtc/media/base/codec.h" 26 #include "webrtc/media/base/codec.h"
27 #include "webrtc/media/base/mediaconstants.h" 27 #include "webrtc/media/base/mediaconstants.h"
28 #include "webrtc/media/base/streamparams.h" 28 #include "webrtc/media/base/streamparams.h"
29 29
30 namespace { 30 namespace {
31 typedef cricket::SctpDataMediaChannel::StreamSet StreamSet; 31 typedef cricket::SctpDataMediaChannel::StreamSet StreamSet;
32 // Returns a comma-separated, human-readable list of the stream IDs in 's' 32 // Returns a comma-separated, human-readable list of the stream IDs in 's'
33 std::string ListStreams(const StreamSet& s) { 33 std::string ListStreams(const StreamSet& s) {
34 std::stringstream result; 34 std::stringstream result;
35 bool first = true; 35 bool first = true;
(...skipping 993 matching lines...) Expand 10 before | Expand all | Expand 10 after
1029 } 1029 }
1030 case MSG_SCTPOUTBOUNDPACKET: { 1030 case MSG_SCTPOUTBOUNDPACKET: {
1031 std::unique_ptr<OutboundPacketMessage> pdata( 1031 std::unique_ptr<OutboundPacketMessage> pdata(
1032 static_cast<OutboundPacketMessage*>(msg->pdata)); 1032 static_cast<OutboundPacketMessage*>(msg->pdata));
1033 OnPacketFromSctpToNetwork(pdata->data().get()); 1033 OnPacketFromSctpToNetwork(pdata->data().get());
1034 break; 1034 break;
1035 } 1035 }
1036 } 1036 }
1037 } 1037 }
1038 } // namespace cricket 1038 } // namespace cricket
OLDNEW
« no previous file with comments | « webrtc/media/engine/webrtcvideocapturer.cc ('k') | webrtc/modules/audio_coding/acm2/acm_receiver.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698